The difference between humans and their closest relatives is partly a matter of taste. Yams, pumpkins, and squash are as bland as potatoes to our tongues today, but to a chimp and our ancestors, wild varieties were bitter and yucky. Now scientists have pinpointed some of the genetic changes that allowed our ancestors to diversify their palates, potentially allowing them to take better advantage of a wide range of foods—and conquer the world.

As humans adapted to new habitats, they had to become open to new culinary experiences. They ate more starchy tuberous roots, learned to cook their meat and bitter root vegetables, and eventually domesticated plants and animals. Those dietary revolutions helped make us human, giving our bodies the extra calories that enlarged our brains, while allowing our guts, jaws, and teeth to shrink as we ate softer, more easily digestible food.

To figure out how these changes evolved, anthropological geneticist George Perry of Pennsylvania State University, University Park, and his colleagues compared the genomes of modern humans and chimpanzees to the newly published genomes of a Neandertal and one of its close relatives, a mysterious human ancestor known as a Denisovan, known only from a few bones found in a Russian cave. All three groups of humans had lost two bitter taste genes, TAS2R62 and TAS2R64, that are still present in chimpanzees, the team reports this month in the Journal of Human Evolution.

Two million years ago, our early ancestors such as Australopithecus or early members of Homo likely found wild yams and other tubers bitter. But as humans began to cook, they could roast tuberous root vegetables long enough that they weren’t as bitter. (Today, hunter-gatherers still rely on roasted tubers as a major source of calories.) At the same time, hominins—members of the human family—lost those two particular bitter taste genes, so they were presumably able to eat a wider range of tuberous plants. Modern humans, Neandertals, and Denisovans all lost the ability to detect the bitter flavor in some wild plants and eventually modern humans bred varieties of squashes, gourds, and yams that are less bitter than the wild types.

The team also found some intriguing differences between modern humans, who arose in Africa in the past 200,000 years or so, and our archaic human relatives, such as Neandertals and Denisovans. Our lineage, for example, carries an average of six copies, and as many as 20 copies, of the salivary amylase gene, AMY1. The gene produces the enzyme amylase in our saliva, which has been thought to help digest sugars in starchy foods, although its role in human digestion is still unproven. By contrast, chimps, Neandertals, and Denisovans carry only one to two copies of the salivary amylase gene, which suggests they got fewer calories from starchy veggies than modern humans. This confirms an earlier finding that Neandertals didn’t have extra copies of the amylase gene and is “definitely a surprise,” says biological anthropologist Richard Wrangham of Harvard University, who was not a co-author on this paper.

Wrangham has proposed that a key human ancestor, H. erectus, relied on cooking starchy tuberous roots to get enough calories to expand its brain. But if so, that distant ancestor wasn’t using extra copies of the amylase gene to extract more calories from these plant foods. He and Harvard postdoctoral researcher Rachel Carmody suggest the amylase copies may have had other functions, such as helping prevent cavities.

And although researchers have proposed earlier that this adaptation took place with the invention of agriculture, Perry and his colleagues have found that hunter-gatherers also carry the extra copies of the salivary amylase gene. This suggests that this adaptation took place in modern humans, after the split with the ancestor they shared with Neandertals about 600,000 years ago but before plants were domesticated 10,000 years ago. “This doesn’t mean that earlier hominins weren’t eating more starch, but perhaps they weren’t getting all of the same benefits as modern humans,” Perry says.

One sign that cooking shaped our ancestors’ genomes as well as our guts is that humans, Neandertals, and Denisovans all have lost a masticatory myosin gene, MYH16, that helps build strong chewing muscles in the jaws of chimps. This may be one result of learning to cook, which softens food, Perry says. This fits with evidence that some early hominins were chefs—Neandertals in the Middle East cooked barley porridge, for example.

Now, Perry and his colleagues are trying to figure out when this gene was lost in the human lineage. The loss of the gene for muscular jaws in Neandertals, Denisovans, and moderns suggests that cooking arose in their common ancestor, H. erectus, he says.