We might not be here if it hadn’t been for some comets carrying water, organic material and pieces of Earth’s atmosphere. Scientists say it’s possible the comets delivered the pieces to us as the planet was forming billions of years ago, after they analyzed ancient air molecules trapped in rock samples and found something unusual.

There was a form of the element xenon — locked in water bubbles inside the 3.3 billion-year-old quartz — which is so rare, the most likely explanation is that comets brought it to Earth during the final stages of the planet’s formation, a study in the journal Nature Communications postulated.

Read: Ancient Carvings Depict Devastating Comet Crash

The isotope, U-Xe, is a volatile element that “is not present in the Earth’s mantle, nor is it found in meteorites,” the University of Manchester explained. “Therefore, the team believe that the U-Xe must have been added to the Earth after a primordial atmosphere had developed.”

sunandcomet Did comets bring Earth’s atmosphere and water while the planet was forming? It’s still a mystery how these crucial pieces of Earth formed but scientists say a comet delivery is possible. Photo: University of Manchester

Volatile elements were crucial to Earth’s atmosphere and oceans forming. But, the study said, young Earth was way too hot to hold on to those volatile elements, which also included other noble gases like helium as well as hydrogen, carbon and nitrogen — they would have boiled off the whistling kettle that was Earth and into outer space. It’s a planetary mystery that implies the elements came from other sources.

“Comets may have brought this component to the Earth's atmosphere during the last stages of terrestrial accretion,” the study said, referring to the physical accumulation of material onto our planet.

That idea is not as far out there as it seems, the study said, because late during the solar system’s formation, “the orbits of asteroids were disturbed by the migration of the giant planets and, for some of them, their trajectories crossed the Earth's orbit.” But even if the comets didn’t bring water with them, which is a debated idea, they still could have brought those volatile elements that helped build our atmosphere.

Read: How Mars Lost Its Air to Space and What That Means for Earth

“The reason that oceans and an atmosphere exist at all is because volatiles were still being added after the Earth formed,” Manchester’s Ray Burgess, a study co-author, said in the university statement. “The puzzle is in identifying where the volatiles came from and what objects carried them to the early Earth.”

Making the process more difficult is that scientists are investigating a cold case: The elements have long since “been thoroughly mixed together by geological processes during Earth’s long geological history,” Burgess said.

But the mineral samples had prehistoric air samples trapped inside them, nicely preserved for analysis.

The solar system and the Earth formed about 4.6 billion years ago, with gravity pulling gases and other material together from outer space, so whether a comet brought special ingredients to the planet or not, it is still made of things that are from out of this world.