Researchers have recently discovered that dinosaurs had an innovative nesting style that may have led to the evolutionary success of modern birds. The study, published in the journal Plos One, details for the first time the link between dinosaur eggshell porosity and different nesting types, and shows how the prehistoric creatures’ nesting styles correlate with the way crocodiles and birds –  the dinosaurs’ closest living relatives – nest.

The question of how dinosaurs incubated their eggs has been debated among scientists for years.

“Nest structures are usually not preserved in the fossil record, making it difficult to determine if dinosaurs buried their eggs during incubation like crocodiles, or if they were incubated in more open nests as in brooding birds,” study co–author Kohei Tanaka of the University of Calgary told “There are many papers that seek the incubation method of dinosaurs, but our research is one of the most comprehensive studies in that it analyzes large datasets on the eggs of both living and fossil species.”

Related: Could humans and dinos coexist?

Tanaka and his team, under the supervision of dinosaur egg and nesting site expert Darla Zelenitsky, studied the fossilized eggshell porosity of 30 different dinosaur species before comparing them with the porosity of eggs belonging to 120 species of birds and crocodiles.

“Fossil eggs are more challenging to study because fossil specimens are often incomplete,” Tanaka said. “However, some of the microscopic features of the eggshell, such as porosity, are preserved, and can be used to infer the types of nests in dinosaurs in the absence complete nests.”

Brooding birds’ eggs, which are incubated in open nests, have a low porosity while crocodile and megapode (also known as incubator or mound–building) bird eggs are highly porous and incubated in buried nests. Most dinosaurs, such as long–necked sauropods and carnivorous theropods, laid low porosity eggs, thus the researchers were able to conclude that they buried their eggs like the modern crocodile. The researchers also found that advanced theropods, including the bird–like maniraptorans, produced high porosity eggshells, hence their eggs were more likely to have been incubated in open nests like those of their closely related living birds.

Related: Archaeologists find world's oldest fava seeds at site in Galilee

“We were surprised that although previous studies on the eggs of oviraptorids suggested they were buried, our results reveal that their eggs were exposed similar to modern bird nests,” Tanaka said.

Still, the team did find evidence that the theropods did partly bury their eggs as well, leading them to conclude that it wasn’t until the arrival of modern birds that open nests with fully exposed eggs began to appear. This would indicate an evolutionary shift in nest and incubation styles between dinosaurs and birds. A switch from buried nests to open nesting and brooding would ensure that the eggs of advanced theropods (including birds) would be safe from ground predators, which may have played a large role in their evolutionary success.

Related: 'Superduck' dinosaur shows how dino crests evolved

“Our results suggest that the change in nesting style occurred in small meat-eating dinosaurs that are closely related to birds,” Tanaka explained. “To better understand dinosaur nesting styles, however, future discoveries of fossil eggs will hopefully fill in the gaps in the dinosaur family tree where eggs are currently unknown.”

The team is planning on using their research to answer other prehistoric nesting questions, such as the length of time it took for dinosaur eggs to hatch.