Getting dirty as a child may well be the answer to a healthier, allergy-free life, according to researchers in California. Photograph: Gerard Fritz/Rex Features

For parents too stretched to make sure their offspring are perfectly turned out at all times, it may just be the scientific cover they've been waiting for.

They will now be able to answer the disapproving tuts of their more fastidious friends by pointing to research which gives biological backing to the old adage that the more germs a child is exposed to during early childhood, the better their immune system in later life

Researchers from the School of Medicine at the University of California found that being too clean could impair the skin's ability to heal. The San Diego-based team discovered that normal bacteria that live on the skin trigger a pathway that helps prevent inflammation when we get hurt.

These bugs dampen down overactive immune responses which can cause cuts and grazes to swell, or lead to rashes, according to research published in the online edition of Nature Medicine.

"These germs are actually good for us," said Professor Richard Gallo, who led the research. Common bacterial species, known as staphylococci, which can cause inflammation when under the skin, are "good bacteria" when on the surface, where they can reduce inflammation.

By studying mice and human cells, researchers discovered that they did this by making a molecule, called lipoteichoic acid (or LTA) , which acted on keratinocytes, the main cell types found in the outer layer of the skin.

The findings bear out the "hygiene hypothesis", first proposed in the 1980s, which suggests that early childhood exposure to bugs might "prime" the immune system to prevent allergies. It has been used to explain why increasing numbers of children in developed countries, where antibacterial sprays and wipes are common, suffer from allergies such as hay fever and eczema. "The exciting implication of the work is that it provides a molecular basis to understand the hygiene hypothesis," said Prof Gallo. "This may help us to devise new therapeutic approaches for inflammatory skin diseases".

According to Allergy UK, rates of allergy trebled in the UK in the last decade, with one in three suffering.

The pressure group Parents Outloud, which campaigns to stop children being "mollycoddled" and "oversanitised" by health and safety regulations, welcomed the research. "Hopefully research like this will help parents realise that it's natural and healthy for children to get outdoors and get mucky and that it doesn't do their health any harm," said a spokeswoman, Margaret Morrissey.