Updated

In depths of the ocean where light can't penetrate, there are fish that generate their own eerie glow — shining spotlights on their prey, flashing warning signs to deter predators, or trading signals within their own species.

And since the first of these creatures lit up the seas about 150 million years ago, the ability to produce light — known as bioluminescence — evolved across fish species far more often than scientists suspected, according to a new study.

Researchers analyzed lineages of glowing fishes, tracing them back to their origins in the early Cretaceous period (145.5 million to 65.5 million years ago). They found that bioluminescence emerged 29 times in marine fish across 14 clades — groups that diverged from a single shared ancestor.

More from LiveScience: See Images of the Amazing Glowing Fish That Light Up Oceans

And there are likely many more instances of evolving bioluminescence radiating throughout the entire tree of life, study co-author John Sparks told Live Science.

Sparks, a curator of ichthyology at the American Museum of Natural History in New York City, explained that before the study, bioluminescence was thought to have evolved just 40 times across all known species — so discovering 29 instances in fish alone is a very big deal.

"Bioluminescence is so bizarre, for it just to evolve once is amazing," Sparks said. "But to show that it's evolved all these times independently just among marine fishes is almost shocking."

Shining on

And fishes are known to use light in a variety of ways, according to study co-author Leo Smith, an assistant curator at the University of Kansas Biodiversity Institute.

Deep-sea hatchetfishes and dragonfishes use light-producing organs called photophores on their bellies for camouflage; the photophore patterns on their bellies mimic light streaming down from the surface and render the fishes effectively invisible to predators that might be looking up. These types of photophores typically appear earliest in a lineage, Sparks said.

Photophores along the sides of fishes' faces, such as dragonfish, are used to communicate within their own species, Sparks said, and tend to first appear further along the family tree, so more recently than other photophores.

Bioluminescence can also help fish catch their prey. Illuminated net devils have long, flexible appendages on their heads called barbels that are tipped with a photophore, which they use to lure smaller fish into their waiting jaws, Smith said.

For bioluminescent fish that communicate with light signals, the arrangement of their light organs varies from species to species — but what each species' signals might look like and what flashing patterns they might use are still unknown, Sparks said.

"We're currently developing camera technology that can capture those patterns in life," he told Live Science. "They need to be very fast to work in low light and see how those unique signals are firing. Cameras can't do that yet, but we're working on it."

The researchers also discovered that once bioluminescence appeared in a lineage, diversification along that lineage into more species soon followed. And groups that used bioluminescence to communicate were particularly diverse and species-rich.

If a lineage of fishes developed unique bioluminescent signals for mate recognition, that ability tended to accompany a radiation of unique species, "like colors and ornamentation in birds being tied to high diversity," Smith told Live Science in an email.

A bright future

What's next? The team will investigate bioluminescence on a genetic level, according to Sparks, to understand how bioluminescent fish evolved to catalyze the chemical that gives them their glow.

"There's this whole system, and we don't know where it comes from," Sparks said. "There are still tons of questions — that's what makes this so interesting."

And the questions apply to more animals than just fishes, Smith added, as scientists begin to identify the number of times bioluminescence evolved independently across the animal kingdom.

"Once all the biodiversity scientists do this, we can begin to ask about the role of bioluminescence and explore the impact of its evolution on animals," Smith said.

The findings were published online today (June 8) in the journal PLOS ONE.

Copyright 2016 LiveScience, a Purch company. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.