The saying “like a moth to a flame” might have to be snuffed out. Some moths in light-flooded urban areas have evolved to resist artificial lights, according to a new study in Biology Letters.

While in graduate school in Basel, Switzerland, evolutionary biologist Florian Altermatt kept tabs on the number of nocturnal insects that flocked to street lamps. “I was mostly interested in what species were coming to the light, and then I noticed there were fewer species coming to the light when in a city,” says Altermatt, who is now at the University of Zurich. The data were set aside in favor of his Ph.D. research, but the question of whether or not insects in cities were impervious to light's siren call stuck with him. Five years later he and Dieter Ebert, an environmental scientist at the University of Basel, decided to formally investigate.

The researchers first collected ermine moth larvae from urban and rural sites throughout France and Switzerland. The moths were raised to maturity. Then, in one go, the scientists released all the adults—320 country moths and 728 city moths—into a dark room with a fluorescent lamp at the far end. Nearly all the moths born in the countryside flew to the lamp, but only about two thirds of the urban moths did the same. The rest of that group remained near their starting point opposite the light.

These results suggest an evolutionary adaptation to light-polluted areas. Such a change could save the lives of many moths: every night hundreds of insects can die of starvation at one street lamp, according to previous studies. But this behavior could also have downsides. “I don't think that this adaptation can really compensate for damage caused by light pollution,” Altermatt warns. For example, in an effort to avoid bright lights, city-dwelling moths may keep to smaller areas of land and thus pollinate fewer plants and encounter fewer mates.