The aptly named Goliath frogs are the world’s largest frog species. They can grow to more than 13 inches long, excluding their legs, and weigh up to seven pounds. Now, scientists think they know not only how Goliath frogs are putting their heft to good use, but also how they evolved to be so big: pushing around large rocks to build nests.

Though these chunky critters are relatively popular, “astonishingly few facts have become known about [their] biology,” a team of researchers write in a new study published in the Journal of Natural History. Goliath frogs, formally known as Conraua goliath, occupy a relatively small range that stretches from southwestern Cameroon into Equatorial Guinea, and they are quite skittish, making them difficult to observe. Due to factors like hunting, large-scale trapping for the pet trade and habitat loss, the amphibians are also endangered, which is why researchers were studying them in the first place.

The team didn’t set out to document the Goliath frog’s nest-building habits. Mark-Oliver Rödel, study co-author and a herpetologist at the Leibniz Institute for Evolutionary and Biodiversity Research, tells Sara Chodosh of Popular Science that the team was looking into the diet of Goliath tadpoles, “in case a captive breeding program might be the last chance for the Goliaths' survival in the future.” During their field work, locals told researchers that the species builds nesting ponds for its tadpoles—a behavior that has not been seen among any other African amphibian. And so the team decided to investigate.

Between February and May of last year, researchers monitored a 1,300-foot stretch along the Mpoula River in western Cameroon. At any hint of a human sound, the shy Goliaths would plunge into the river, so it was hard to observe the frogs directly. But the team was able to identify signs of nest-building at 22 breeding sites, 14 of which contained nearly 3,000 Goliath eggs each.

The nests could be categorized into three types. With one, the frogs simply cleared leaf litter and other sediment out of rock pools in the river bed, which is to say that they were “using pre-existing structures for breeding,” the study authors note. With the second type of nest, the Goliaths enlarged existing shallow pools by pushing gravel and leaf litter to the edges of the pool, forming a dam. But perhaps most impressive was the third type of nest, which saw the frogs dig depressions into the gravel riverbanks and encircle them with larger stones and rocks—effectively creating their own ponds.

These rocks were quite heavy, with some weighing up to 4.4 pounds—more than half the frogs’ weight. Rödel tells Live Science’s Laura Geggel that it was probably the males doing the heavy lifting, using their “huge and very muscular hind legs.”

Surrounding nests with gravel and rocks may create a barrier against predators—like fish and shrimp, which feed on frog eggs and larvae—while also preventing fluctuating water levels from washing the spawn away. Additionally, all nest types had been cleaned of debris, which may help Goliaths keep an eye out for predators. The frogs do, in fact, seem to be protective parents. Hoping to get a good look at the elusive species, the researchers used a camera trap to record a time-lapse video at one of the nests. Shortly after nightfall, a large frog appeared, standing guard over its brood until just a few minutes before dawn. Researchers could not determine the sex of the adult parent, but interviews with local farmers and frog hunters suggest that it might have been female.

“The most detailed description we got (from one frog hunter) was that the male would construct the nest while the female waits in proximity,” the study authors write. “Once the nest is finished, the male whistles to attract the female, which then is grasped by the male and eggs are deposited. Afterwards the female would guard the nest and subsequently open the nest towards the river.”

Digging nests and hauling stones is, as the researchers put it, a “serious physical task”—one that could explain why Goliaths have evolved to be so large. Chodosh reports that moving forward, the team plans to return to Africa and set up additional camera traps, with the goal of capturing the building process in action. But for now, the new study demonstrates how much scientists have yet to discover about an iconic species that is at risk of disappearing.

“The fact that we've only just discovered these behaviours shows how little we know about even some of the most spectacular creatures on our planet,” Rödel says. “We hope that our findings, combined with further ongoing research, will improve our understanding of the needs of the Goliath frog so we can help support its continued survival.”