According to the hygiene hypothesis, bad things can happen if this early exposure doesn't take place or if it doesn't include the right microbes. The immune system can become overly sensitive, overreacting to non-threats such as pollen or dander as if they're potentially harmful. When combined with certain genetic traits, this process can lead to conditions such as asthma and allergies, says Kathleen Barnes, an immunogeneticist at Johns Hopkins University who specializes in the genetics of asthma.
Barnes' work has revealed that although genes play a key role in the development of asthma, changing a population's exposure to microbes — by protecting them from parasitic diseases, for example — can make asthma rates rise. That suggests that hygiene may also play a role in asthma.
"It can't all be due to genes, because if we look at the prevalence of asthma or diseases of inflammation over the past 50 years, we see it's definitely on the rise," Barnes says. "It's some interaction between the genes and the environment that's causing these rates to skyrocket."
But researchers can't say which particular interactions with the environment help prevent disease later on. That's because exposures tend to come in combinations, and teasing apart their effects on the body is difficult.
Take farming, for instance. Several studies have suggested that growing up on a farm can protect children from allergies and other immune-system-related conditions, but it's hard to know which element of farm living does the trick.
A 2012 study of Amish and Swiss farm and non-farm children found that the farm-dwelling kids had significantly lower rates of asthma, hay fever and eczema. But the farm dwellers differed from their non-farm peers in several ways: They had more exposure to livestock and the microbes that come with them; they were more likely to drink raw milk, which contains microbes not found in pasteurized milk; and they tended to have more siblings at home.