When award-winning Drop The Dead Donkey writers Andy Hamilton and Guy Jenkin looked around for a new project together, they found the answer in their homes.

Outnumbered, their first collaboration for eight years, is based partly on their own experiences of bringing up young families.

"We've been talking about doing a comedy half-hour for some time and since we both have young families that seemed a good place to start. So we began nurturing the idea a while back," explains Jenkin, the father of twin daughters.

Hamilton had already written a few scenes for his daughter Isobel, who was seven at the time, in the 2001 BBC sitcom, Bedtime. "Co-star Kevin McNally suggested I didn't show her the script, just give her my thoughts. Isobel customised her lines, and it did look very natural," he says.

That set the writing pair thinking about getting genuine, realistic looking performances out of young children. "We noticed this great dichotomy between the representations of parenting in sitcoms with the complete chaos of real life," continues Jenkin.

"You rarely get the feeling that children in sitcoms are real. They tend to be the same type of character - the smartarse who says adult things - and they're rooted to the spot, staring at the camera, because they've been told to stand in one place and say the lines.

"We decided to do something that hadn't been tried before, bounced some ideas around and we got very keen on this idea of involving improvisation very quickly."

Outnumbered was born. Hugh Dennis, Claire Skinner and Samantha Bond star in the comedy series following the daily chaos of family life with two parents and three young children - boys aged seven and 11, and a five-year-old girl - locked in an unequal contest. The difference is that the children have been allowed to improvise, resulting in a very different series to a studio-bound show like My Family.

Dad (Hugh Dennis) works in an inner city school, mum (Claire Skinner) is a part-time PA with a very demanding boss. Topics raised in the series range from racism and weak bladders to underage drinking and Nazis.

The child actors were allowed to improvise their lines. Hamilton says they wrote the storyline and dialogue, adding, "But we try to create an environment where the kids will spin off into something or they'll express themselves in a way that's individual to them.

"In most cases, the adults don't get any real warning, and then we step into genuine improvisation. There is a script, but we never show it to the children and they never learn their lines."

Because the project was so unusual, the writers knew it would be difficult to explain to the BBC commissioning editor, so they had a sample 20-minute pilot filmed at Jenkin's house last year.

Casting the adults was easier than finding young actors. The casting director avoided stage school talent, undertaking a lengthy audition process involving game-playing in a bid to find children who would enjoy the filming process.

Tyger Drew-Honey, who plays 11-year-old Jake, will soon be seen as a regular character in The Armstrong And Miller sketch show on BBC1, while Daniel Roche has appeared in commercials and Casualty. For the youngest, five-year-old Ramona Marquez, this is her first acting role. She was spotted by Jenkin's wife at a birthday party.

The BBC decided Outnumbered would sit happily in the bedtime slot, run as more of an event across three consecutive nights on two consecutive weeks.

Filming took place over an intense four-week period, restricted by performance regulations meaning children under nine can only work a maximum three hours a day in 45-minute chunks.

The children didn't learn lines. Instead they were given a verbal outline of whatever situation the characters found themselves in and were then encouraged to express things their own way.

"We decided we'd try and create an atmosphere on set in which the children could relax and be themselves," says Hamilton. "Filming comes with a lot of ritual and paraphernalia, and we tried to get rid of as much of that as possible."

For the adult actors, this out-of-the-ordinary shooting schedule took some getting used to. Even though their lines were scripted, they often had to react to the part-scripted, part-improvised dialogue of the youngsters.

"It was a real assault course for the actors," says Jenkin. "It was like being a real parent. You don't necessarily know what trouble the kids are going to throw up.".

Claire Skinner loved the relaxed atmosphere on set to ensure the children didn't get bored or fed up. "As far as they were concerned, most of the time they were just playing about and having fun. It was great to be surrounded by happy children which made it a really fun shoot".

Outnumbered is on BBC1 on Tuesday, Wednesday and Thursday at 10.35pm.