The glowing yellow, green, or red fireflies that emerge from the grass are a sign of summer. Despite there being around 2,400 species of fireflies on Earth, these bioluminescent insects are facing threats to their survival due to deteriorating habitat conditions.
Recently, scientists have started to challenge the existing hypothesis regarding why fireflies evolved their glow. New genetic analysis may play a crucial role in helping fireflies adapt to their changing environment and survive.
[Related: How do fireflies power their blinking butts?]
A new hypothesis for how fireflies got their glow
For a long time, scientists believed that the bright light emitted by fireflies in the Lampyridae family evolved as a warning signal to predators, indicating their toxicity. Over time, this glow may have also been repurposed as a mating signal.
In a recent study published in the journal PNAS Nexus, a team in China conducted a genetic analysis of fireflies to trace the evolution of lucibufagins, the chemical compounds that make fireflies toxic. Their findings suggested that the toxin evolved later and may not be the primary reason for bioluminescence in fireflies.
The study suggested that the glow of fireflies may have evolved as a response to a stressful situation, such as low oxygen levels. The antioxidant properties of luciferin, a component of firefly bioluminescence, may have helped fireflies cope with oxygen depletion in the past.
[Related: Mass extinction 183 million years ago offers dire warning for modern oceans.]
Today, fireflies face challenges due to climate change. Their breeding cycles and habitat quality are significantly impacted by subtle changes in temperature and other environmental factors.
According to a study published in the June 2024 edition of Science of the Total Environment, fireflies are sensitive to short-term weather conditions, long-term climatic trends, and urban development.

Fireflies are less common in areas with significant light pollution at night, indicating the negative impact of human encroachment on their populations.
[Related: Why artificial light—and evolution—trap moths.]
While some firefly species have adapted to environmental changes, others are more vulnerable. Conservation efforts need to consider the complexity of natural ecosystems and tailor strategies accordingly.
How to help fireflies
Although fireflies are not currently considered endangered, their numbers are declining. Providing additional habitat, avoiding pesticide use, and reducing light pollution can help support firefly populations.
Entomologists recommend incorporating wild or native plant species in yards or gardens, as well as turning off unnecessary outdoor lights to create a more hospitable environment for fireflies.
By taking these steps, we can help ensure that future generations can continue to enjoy the beauty of fireflies lighting up the night sky.