Mucus may be gross, but it also can keep germs in check.

A study in Nature Microbiology explains how: Sugar.

Biophysicist Katharina Ribbeck at the Massachusetts Institute of Technology studies compounds in mucus called mucins, molecular chains densely studded with sugars. They "look like mini bottlebrushes," she said, except bristling with sugar molecules where whiskers would be.

The textbook model of mucus — a filter that traps and eliminates microbes — isn't accurate. Microbes "don't get trapped at all," she said. Inside a glob of mucus, bacteria swim freely. A lone drifter, as opposed to many germs gathered in clumps, makes an easier target for immune cells.

But not all bacteria need to be killed. Only a minority are harmful. "We provide the microbes the home, and in return, they do a service," Ribbeck said. Mucus, she suspected, might help domesticate germs into friendlier inhabitants.

Kelsey Wheeler, a doctoral student, said it was the first study to identify that sugar grafted to the mucins "is responsible for suppressing antagonistic microbial behaviors."

Pediatrics professor Lars Bode said, "Instead of using antibiotics when these things turn against us, why don't we prevent them from turning against us in the first place?"

Research not yet published suggests that the sugars can tame other types of microorganisms, including the bacteria Streptococcus mutans, Ribbeck said. That could be critical as more bacteria become resistant to antibiotics.

She said, "changing their ability to cause infections could be a really potent strategy."