If there's one thing we known from the slew of exoplanets detected over the past few decades, it’s that giant planets are not afraid to cozy up to their stars. However, because the region near an active young star is not the ideal place to build large planets, astronomers tend to think oversized exoplanets first form far from their host stars before migrating inward as they age.

Now, new research suggests the biggest planet in our solar system, Jupiter, likely underwent its own great migration early in its life. And it turns out it was quite the trip.

According to the study, which has been accepted for publication in the journal Astronomy & Astrophysics, although Jupiter now sits an average distance of 5.2 astronomical units from the Sun (1 AU is the average Earth-Sun distance), the core of the gas giant likely formed some 18 AU away. That’s about twice as far as present-day Saturn is from the Sun. Furthermore, Jupiter apparently made the entire journey in less than about a million years, which is just a blink of the eye in astronomical terms.

Although the idea of a wandering Jupiter is not new, “This is the first time we have proof that Jupiter was formed a long way from the Sun and then migrated to its current orbit,” said lead author Simona Pirani, a doctoral student at Lund University, in a press release. “We found evidence of the migration in the Trojan asteroids orbiting close to Jupiter.”

Meet the Trojans

Jupiter’s Trojan asteroids are a mysterious bunch. Sharing an orbit with the giant planet, these dark and reddish bodies are divided into two main groups: the “Greek Camp,” which leads Jupiter, and the “Trojan Camp,” which trails behind.