A population genetics study has found that the parasites are responsible for making the body's immune proteins adapt themselves to turn into inflammatory defenders.
Conducted by a team of researchers in Italy, the study also suggested that parasites also influence some of those genes to turn into risk factors for intestinal disorders.
Usually parasite-driven selection leaves a footprint on our DNA in the form of mutations known as "single nucleotide polymorphisms" (SNPs).
Making sure that genetic variation (in the form of multiple SNPs) is maintained within certain immune genes over time helps ensure that the host can fend off different infections in different environments.
In the study, researchers led by Matteo Fumagalli, sift through 1,052 SNPs in genes that code for immune proteins called interleukins from roughly 1000 people worldwide.
Out of the 91 genes assessed, 44 were found to have signatures of evolutionary selection, which meant that the genetic variation was neither due to chance nor to the migration of populations over time.
And some of that variation was linked with the diversity of parasites that live alongside humans.
The data revealed that having lots of different parasites around has shaped the evolution of our interleukin genes.
Generally, parasitic worms appear to have had a more powerful influence on certain interleukin genes than smaller microbes such as viruses, bacteria, and fungi.
But it doesn't surprise senior author Manuela Sironi, because worms typically evolve slower than bacteria or viruses, giving their human hosts time to adapt in response.
Some of the genes that were shaped by worm diversity made perfect sense, as the proteins they encode help generate the precise type of immune response required to rid the body of worms.
However, other genes seemed to be influenced more by the diversity of viruses, bacteria, and fungi than by that of worms.
The results of the study will appear in an upcoming issue of the Journal of Experimental Medicine.