Flashes of Brilliance: Firefly Code

firefly code
S.H. LeeWatch for flashes of firefly code during the late spring and early summer months, when the insects mate.

If you think fireflies’ flashes are simply random, pretty bursts of light, think again.

“They’re not just putting on a fantastic light show for our enjoyment,” says Sara Lewis, a professor of biology at Tufts University and the author of Silent Sparks: The Wondrous World of Fireflies. “Those are the silent love songs of the male firefly.”

Like any music, these “songs” have variations. Some of the differences you can see with your own eyes, but others are only recently coming to light.


Firefly larvae live underground for about two years, voraciously eating earthworms in warmer seasons and hibernating in the winter. When they’ve reached a certain size, usually in their second April or May, they surface and go through metamorphosis, emerging a few weeks later as adult beetles. Most of the approximately 30 species of fireflies in the Northeast are capable of bioluminescence, the chemical reaction that produces light.

Many species of adult fireflies don’t eat, instead surviving on fuel stored when they were larvae. During their brief but dazzling two-week lifespan, the adults will mate with multiple partners, until the females lay their fertilized eggs on or just below the surface of the ground. Those eggs hatch a few weeks later as larvae, starting the cycle again.


To court a female, a male firefly will flash his abdominal lantern at twilight. If she’s interested, a female of the same species will respond with her own flash.

The fireflies’ flash patterns identify their species. Some of these insects, also known as lightning bugs, make a single flash then, after a certain amount of time, flash again. These are called single pulse species. Others make a pair of flash pulses, wait, then make another pair of flashes. These are paired pulse species. Other species make five or six flashes, wait, then flash five or six more times.

“Those are things anybody with a good eye can see,” Lewis says. Her book includes a guide to help you identify species by their pulses.

But that’s not the whole story. Lewis and her team have discovered that the duration and frequency of flashes varies among males within the same species. The difference may be as small as 50 milliseconds. “It’s difficult for us to see with our eyes,” Lewis says. But “it’s not subtle to a female firefly.”

To track how females respond to different frequencies, Lewis has created what she calls her “firefly opinion polls.” Using computer-controlled LED lights to mimic the males’ flashes, she has found that female fireflies respond more often to longer flashes—or, in the case of paired pulse species, to more frequent flashing.


What’s the appeal of the flashier light shows? In some species, Lewis says, the male’s flash pattern is associated with the size of the nuptial gift he can offer to each of his female partners. A longer or more frequent flash means a bigger gift.

This nuptial gift is not a euphemism. It’s essentially a snack pack a male delivers to a female during mating, providing extra nutrition for her. Females that receive more and larger nuptial gifts lay more eggs, so males with bigger gifts sire more offspring.

The male’s nuptial gifts get smaller over his lifespan, as his proverbial larder becomes bare, so what the female firefly sees does not always indicate what she’ll get. Still, in these summer romances, the flashier suitor is often a good bet.


Search AMC Outdoors and Blogs

Search for:

Heather Stephenson

AMC Outdoors, the magazine of the Appalachian Mountain Club, inspires readers to get outside and get engaged. Learn more.

Most Recent