Today, the world is warming. But from about 720 to 635 million years ago, temperatures swerved the other way as the planet became encased in ice during the two ice ages known as Snowball Earth.

It happened fast, and within just a few thousand years or so, ice stretched over both land and sea, from the poles to the tropics. Life lived in the oceans at the time, and the encroaching ice entombed that life, cutting it off from both the sun and the atmosphere.

“This is the one time when Earth’s natural thermostat broke,” said Noah Planavsky, a biogeochemist at Yale University. “The question on everyone’s minds was: How did life actually make it through this?”

Glaciations can drive mass extinctions of life. Yet life, including perhaps our distant animal ancestors, somehow survived these deep freezes. In research published Monday in Proceedings of the National Academy of Sciences, Dr. Planavsky and his colleagues report the discovery of oases just beneath the ancient ice sheets that likely helped life persevere.