The common fruit fly. (Eduard Andrica/Shutterstock)
In a nutshell
- Desert fruit flies have evolved to be attracted to heat, not by changing their heat sensors, but by rewiring how their brains interpret those heat signals, flipping a natural aversion into a preference.
- The same heat-sensing protein (Gr28b.d) triggers opposite behaviors in different fly species: heat avoidance in common lab flies and heat attraction in desert-dwelling D. mojavensis, depending on how the brain is wired.
- Instead of avoiding dangerous heat, these flies learned to seek it out, potentially helping them navigate the extreme temperature swings of the desert.
EVANSTON, Ill. — Some animals get tougher to survive harsh conditions. Others get smarter. But a certain desert fruit fly has evolved to crave the very thing that could kill it. Scientists from Northwestern University have discovered that these tiny insects have adapted to think of deadly temperatures as a warm hug instead of a death trap.
While most creatures, including the common fruit fly found buzzing around your kitchen, desperately avoid high heat, their desert-dwelling cousins have learned to do the opposite. These hardy flies have adapted to actually be drawn to extreme heat.
Rather than simply developing thicker skin or better cooling systems, these desert flies rewired their brains to perceive potentially deadly heat as appealing rather than threatening.
Two Paths to Desert Survival
Published in Nature, the study examined three different fruit fly species living in dramatically different environments. Researchers compared the common lab fly Drosophila melanogaster (which prefers a comfortable room temperature around 77°F) with D. persimilis from cool mountain forests and D. mojavensis from the scorching Sonoran Desert.
Sarah Becan for the Gallio Lab)
They found two completely different strategies for surviving in extreme conditions. Mountain flies, D. persimilis, simply became more sensitive to heat, setting off their internal fire alarms at lower temperatures (around 70°F) to avoid any risk of overheating.
But the desert flies chose a different approach. Instead of becoming more cautious about heat, their brains adapted over millions of years of evolution. They kept the same basic heat-sensing equipment but completely reversed how their brains interpret those signals.
How Did These Flies Adapt?
To crack this biological mystery, scientists focused on a protein called Gr28b.d. It is kind of like the fly’s internal thermometer. This protein sits in nerve cells and springs into action when temperatures rise, sending urgent messages to the brain.
Researchers tested how this protein responds to heat in different fly species. They heated up individual cells containing these proteins while measuring their electrical activity.
Mountain flies’ proteins activated at around 70°F, laboratory flies at 79°F, and desert flies at 84°F. But when desert flies’ heat sensors activate, instead of triggering “run away!” messages, they send “come closer!” signals to the brain.
To prove this wasn’t a random occurrence, scientists genetically swapped the heat sensors between species, giving desert fly sensors to laboratory flies and vice versa. Laboratory flies with desert sensors started seeking out temperatures they would normally avoid, while desert flies with laboratory sensors lost their heat-seeking behavior.
Researchers also mapped the neural highways carrying temperature information through fly brains. By tracing individual nerve cells, they discovered that desert flies had rewired their brain connections.
In normal flies, heat sensors connect to brain regions that process danger and trigger avoidance. But desert flies rerouted these connections, sending heat signals to brain areas associated with attraction and approach behaviors instead.
When scientists artificially activated heat sensors in desert flies, the insects moved toward the stimulation rather than away from it. They had literally evolved to find potentially lethal temperatures irresistible.
Evolutionary Gamble
This evolutionary strategy is actually risky. Desert temperatures routinely exceed 104°F—hot enough to kill most fruit flies within minutes. Yet desert flies actively seek these conditions out.
Researchers believe this counterintuitive behavior might actually be a sophisticated survival strategy. Desert environments are incredibly unpredictable, with temperatures swinging from near-freezing at night to life-threatening heat during the day. In such chaotic conditions, being able to track and follow temperature changes, even dangerous ones, might be more valuable than simply avoiding heat altogether. This heat-seeking behavior might help flies find the warmest spots for optimal metabolism and reproduction.
Animals can rapidly evolve entirely new ways of perceiving and responding to their environment when faced with extreme challenges. Desert flies’ solution represents one of the most dramatic examples of behavioral evolution ever documented. Rather than evolving entirely new sensors or protective mechanisms, these flies simply repurposed their existing equipment.
Paper Summary
Methodology
Researchers studied temperature preferences in three fruit fly species using choice experiments where flies could pick between different temperatures. They measured how heat-sensing proteins responded to temperature changes in lab-grown cells using electrical recording techniques. Scientists swapped genes between species to test their functions and used advanced brain imaging to map how temperature signals travel through fly nervous systems. They also analyzed gene activity patterns using RNA sequencing.
Results
Mountain flies (D. persimilis) preferred cool temperatures (59-68°F) and had heat sensors that activated at lower temperatures. Laboratory flies (D. melanogaster) preferred moderate temperatures around 77°F. Desert flies (D. mojavensis) actively sought hot temperatures (86-95°F) despite having heat sensors that functioned normally. The key difference was that desert flies had rewired their brain circuits so heat sensors triggered attraction rather than avoidance behaviors. Gene swapping experiments confirmed that the same molecular machinery produces opposite behaviors depending on how brain circuits are wired.
Limitations
The research focused on only a few fruit fly species and used laboratory conditions that may not fully reflect natural environments. While the research identified key molecular and neural mechanisms, it couldn’t determine exactly how these evolutionary changes occurred over time. The behavioral experiments tested only temperature preferences and not other aspects of thermal adaptation like survival rates or reproductive success in extreme conditions.
Funding and Disclosures
This research was supported by grants from the National Institutes of Health National Institute of Neurological Disorders and Stroke, the PEW Scholars Program, and the Trienens Institute for Sustainability and Energy at Northwestern University. The authors declared no competing interests.
Publication Information
The paper “Evolution of temperature preference in flies of the genus Drosophila” is authored by Matthew Capek, Oscar M. Arenas, Michael H. Alpert, Emanuela E. Zaharieva, IvĂ¡n D. MĂ©ndez-GonzĂ¡lez, JosĂ© Miguel Simões, Hamin Gil, Aldair Acosta, Yuqing Su, Alessia Para, and Marco Gallio. It was published in Nature (Volume 641, pages 447-455) on May 8, 2025.







