In around a billion years, the sun will become hot enough to boil all the oceans on our planet, and life as we know it will be destroyed.
The fate of life on Earth, scientists think, is more or less sealed.
But a passing star could prove to be an unlikely savior, according to a new study by scientists from the University of Bordeaux, France, and the Planetary Science Institute in Tucson, Arizona.
The researchers ran 12,000 simulations to see what would happen if a star passed within 100 astronomical units (about 9.3 billion miles) from Earth.
The simulations showed that our solar system is remarkably stable. In 92 percent of cases, the solar system would remain almost intact even as a star passed by the solar system.
"I thought more would happen," Sean Raymond, a study author from the University of Bordeaux in France, told New Scientist. "It's really not that easy to mess with planets' orbits – a star has to get really into another star's business to mess with its planets."
Still, there's a chance the passing star could pull our planet out of harm's way – albeit a slim one. In 0.28 percent of the simulations, the star pulled the Earth out of its orbit and into a more temperate region, Raymond said in a blog post.
This manifested in a number of ways. In some simulations, Earth remained in the solar system but was pulled to a region beyond Pluto that's about 10 percent cooler than our current orbit.
In other simulations, Earth was kicked into interstellar space, ending up in the Oort cloud, about 2 billion light years away, or as a free-floating planet in space.
As bizarre as it might seem, this may not be the worst-case scenario, said Raymond in a blog post. "It is much harder to un-roast a fried planet than to heat up a frozen world," he said.
"If they possess modestly thick hydrogen atmospheres, free-floating planets can trap enough heat to maintain liquid water on the surface," he said.
There are also a few scenarios where the star captured the Earth as it flew by.
However, in scenarios where the Earth was taken away from the broiling zone, it wasn't automatically saved. In many cases, it ended up crashing into the moon or Venus.
There's only a 1 percent chance a star could fly by our solar system in the next billion years, and the simulations predict a 1 in 350 chance of Earth being kicked into a habitable orbit.
So taken together, "that's a 1 in 35,000 chance that the long-term prospects for life on Earth will be rescued by a passing star," said Raymond in a blog post.
"That's about the same odds as randomly pulling the ace of spades from two separate decks of cards while also rolling a combined 10 with two dice. Not the best odds," he said.
The research findings were published in the peer-reviewed journal Monthly Notices of the Royal Astronomical Society on November 27.
This article was originally published by Business Insider.
More from Business Insider: