A new study has uncovered a surprising link between parasitic infections and a woman’s fertility rate, finding that while some infections compromised a woman's fertility, others seemed to increase it.

Over the span of nine years, researchers from the University of California, Santa Barbara observed the fertility rates of women who belonged to the indigenous Tsimane community in central Bolivia. While the average Tsimane woman has nine children over the course of her reproductive lifespan, the team observed that infections from a group of parasitic worms known as helminths had a noticeable affect on this output — they affected women’s ability to conceive. As a result, women who had hookworm infections ended up with about three fewer children than average, while women with roundworm infections had about two more children than average.

Helminth infections are most common in developing countries, where poor sanitation causes feces to contaminate the soil. The infection causes fatigue, diarrhea, and, in children, impaired physical and cognitive growth. Yet, aside from anemia, many Tsimane people often experience asymptomatic infections. Their bodies may not feel any different, but their immune systems still react to the foreign body. This response in turn affects a woman’s fertility, for better or worse.

"Although we don't know the precise mechanism behind these results, our findings are still compelling and suggest that immune modulation — via our 'old friends' the intestinal worms — can have far-reaching effects on the body," co-author Michael Gurven added in a press release.

In addition to parasites, scientists have found sexual activity can also bring about an immune system response that affects a woman’s chance of conception. Although the immune system is designed to attack and destroy foreign bodies, a recent study found sex also prompts a woman’s body to increase production of helper T cells, which protect foreign cellular structures that aid with reproduction, such as sperm. This change occurs after sexual intercourse, regardless of where in the fertility cycle the woman is. In a press release, lead researcher Dr. Tierney Lorenz said it’s like "the sexually active women's immune systems were preparing in advance to the mere possibility of pregnancy."

Source: Blackwell AD, Tamayo MA, Beheim B, et al. Helminth infection, fecundity, and age of first pregnancy in women. Science. 2015.