(CNN) — It’s all about dogs, dust and microbes.

Scientists have long known that kids who grow up with a pet, like a dog or cat, or live on a farm with plenty of livestock are less likely to develop asthma or allergies.

They didn’t know what exactly protected these kids, but speculated that it had something to do with the “hygiene hypothesis” — the idea that modern lifestyles are too clean, and therefore our immune systems aren’t exposed to enough bacteria, viruses and parasites (the kind that likely hitch rides in pet hair) to build up proper immunity.

Now, researchers think they are getting closer to a possible explanation.

A team of researchers from the University of Michigan exposed a group of mice to dust from a dog owner’s home, then doused them and a population of mice who weren’t given dog dust to two asthma-related allergens (including cockroach compounds).

The mice that had been exposed to the dog dust showed much lower inflammation in their airways, and produced less mucus than the mice that received no dust or dust from a non-dog household.

But it wasn’t the dust that was protective, but what lived in the dust — microbes that actually reshape the community of living organisms in the rodents’ gut. These changes influenced the immune response of the mice and their ability to fight off certain allergens.

Specifically, the researchers found that a single bacteria called Lactobacillus johnsonii was very prominent in the guts of the mice who lived with dog-related dust. When the researchers gave a live form of the bacteria to the mice that had not been exposed to dog dust, they found that the animals developed similar protection against allergens that the dust-exposed mice had.

What’s encouraging about the findings, which were published in the journal, Proceedings of the National Academy of Sciences, is the fact that the dust associated with the dogs seemed to prompt an immune response against microbes that have been linked to asthma in kids.

So the results could lead to future studies on how manipulating gut bacteria — possibly with probiotics or other microbial strategies — could treat or protect children from allergies and asthma.

###

By Alexandra Sifferlin
December 18, 2013
TIME.com