Humans can thank their Neanderthal ancestors for giving them the genes that fight diseases, but also for their allergies, new research suggests.

Genetic variants found in modern humans that originally came from Neanderthals may predispose the human immune system to overreact to environmental allergens, according to two new studies published today (Jan. 7) in the American Journal of Human Genetics.

Ancient Human With 10 Percent Neanderthal Genes Found

But these Neanderthal loaner genes may have had a silver lining. The studies also found that interbreeding with Neanderthals may have helped ancient humans, who came from Africa, get a head start in settling Europe.

“Neanderthals, for example, had lived in Europe and western Asia for around 200,000 years before the arrival of modern humans. They were likely well-adapted to the local climate, foods and pathogens,” Janet Kelso of the Max Planck Institute for Evolutionary Anthropology in Leipzig, Germany, said in a statement. “By interbreeding with these archaic humans, we modern humans gained these advantageous adaptations.”  [Our Closest Human Ancestor]

Gory Remains Of First Known Murdered Human Found

Neanderthals interbred with humans when humans first emerged from Africa into Europe, about 50,000 years ago. Studies suggest the last Neanderthal-human mating could have occurred as recently as 37,000 years ago.

As a result of this interbreeding, genetic studies suggest, as much as 2.5 percent of the DNA of today’s Europeans came from Neanderthals, while other research suggests that up to 6 percent of modern DNA originated with ancient hominins. That group includes both Neanderthals and a mysterious set of human ancestors that lived in Siberia, called Denisovans.

Past research suggested that many of the genes that modern humans inherited from Neanderthals play a role in the modern human immune system, though the exact roles remain unclear.

Neanderthal Claw Necklace (Or Bracelet) Found

In the new study, researchers trawled through a vast trove of modern DNA from the 1000 Genomes Project. The scientists compared this modern human DNA with genomes from ancient hominins, focusing on about 1,500 genes that have previously been found to play a role in the body’s first line of defense against bacteria and viruses, called the innate immune system.

Next, the team constructed a time line of when changes in some of these genes became widespread in the population, also determining whether those changes had been inherited from ancient hominins such as Neanderthals.

The researchers found that most of the changes in these genes occurred between 6,000 and 13,000 years ago, which was not surprising, given that humans transitioned from a hunter-gatherer to an agricultural lifestyle in this time period. However, three genes had seemed to change before that, right around the time that humans first encountered Neanderthals.

Itchy Skin, Diarrhea Evolved To Promote Good Health

These genes contained the instructions to build a family of proteins called Toll-like-receptors (TLR). These proteins — TLR 1, 6 and 10 — sit on the cell surface and bind to foreign invaders such as bacteria and fungi. This, in turn, mobilizes the rest of the immune system to fight an infection.

Separately, Kelso’s team searched for the stretches of DNA that were the most similar among humans, Neanderthals and Denisovans. This hunt similarly led the team to the TLR 1,6 and 10 genes.

The researchers also showed that, in humans, people with the archaic versions of these genes had a more robust response to microbes such as Helicobacter pylori than did people with other variants.

9 Myths About Seasonal Allergies

“What has emerged from our study as well as from other work … is that interbreeding with archaic humans does indeed have functional implications for modern humans, and that the most obvious consequences have been in shaping our adaptation to our environment — improving how we resist pathogens and metabolize novel foods,” Kelso said.

That hypervigilant immune response, however, may have a dark side. Studies in large populations have found that people with the archaic versions of the gene are more likely to have allergic diseases, which occur when people’s bodies respond to normal environmental triggers as if they are dangerous threats.

More From LiveScience:

  • Top 10 Mysteries of the First Humans

  • Denisovan Gallery: Tracing the Genetics of Human Ancestors

  • In Photos: New Human Ancestor Possibly Unearthed in Spanish Cave

Original article on Live Science.

Copyright 2016 LiveScience, a Purch company. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.