Galactic dynamics · WebGPU · From JPL and Gaia-era data
The Earth goes round the Sun while the Sun goes round the Milky Way at 250 km/s. Slide time from a year a second to a billion years a second and watch the planets trace stretched spirals, then the Sun loop the galaxy nineteen times since the Earth formed, bobbing through the disc as it goes.
The Earth circles the Sun once a year, about 1 AU out. Meanwhile the Sun, with everything around it, circles the centre of the Milky Way at about 250 km/s. That is 52 AU every year, so in the time the Earth goes round once, the whole solar system moves forward 52 times the Earth's distance from the Sun. The Earth's real path through the galaxy is a spiral, but stretched so far that it is almost a straight line with a gentle wobble.
Start at the slow end of the time slider and you see exactly that. Each trail is a planet's path in the galaxy's frame. The Earth's wobbles once every 52 AU, and Neptune's barely bends. Pick Slowed 20×to shrink the Sun's speed and the coils close up into a visible helix. That view is a teaching aid, and only that one is.
A widely shared animation shows the planets streaming behind the Sun in a cone, like the tail of a comet, with the Sun dragging them through space. Two things are wrong with it. First, nothing is being dragged: the Sun and the planets all fall round the galaxy together, and the planets are as often ahead of the Sun as behind it. Second, the angle is wrong. The plane of the planets is tilted 60°to the plane of the galaxy, and the Sun's direction of travel is about 60° from that plane too, not along it and not square to it. The model gets the tilt from the official transformation between the sky's coordinates and the galaxy's, which puts the north pole of the planets' plane at galactic longitude 96.38° and latitude 29.81°.
Slide to the fast end and the solar system shrinks to a point. The Sun is about 8.2 kiloparsecs (27,000 light-years) from the black hole at the centre. In this model one lap takes about 246 million years, so the Sun has been round about nineteen times since the Earth formed. One lap ago, the first dinosaurs were just appearing.
The orbit is not a circle. The Sun swings in and out between about 8.1 and 10 kiloparsecs every 184 million years. It also bobs through the disc, rising to about 110 parsecs above it and sinking as far below, once every 94 million years. Today it is 21 parsecs above the midplane and still climbing at 7 km/s. Choose ×10 heights to see the bobbing from far away.
The Sun moves about 20 km/s faster than a circular orbit would at its distance, so its orbit is a little eccentric. That comes from two measurements that do not quite agree: the galaxy's rotation curve gives 229 km/s for a circular orbit, and the motion of the central black hole across the sky gives the Sun 248 km/s. Astronomers are still working out the gap.
Between the two extremes, around a light-year to a few hundred, the view shows a sample of neighbour stars. They share the galaxy's rotation, but each also has its own motion of a few tens of km/s. The Sun moves through them at about 24 km/s, toward the constellation Hercules. The neighbours here are drawn at random with the right spread of speeds; they are not a catalogue of real stars.
The Milky Way's gravity is MWPotential2014, a standard model with a bulge, a disc and a dark-matter halo. It is scaled here to the latest distance to the centre and rotation speed. The Sun's orbit is integrated from its measured position and velocity, in double precision, from the Earth's formation to five billion years ahead. A check script confirms that energy holds to one part in 10¹² over the whole run, and the angular momentum about the axis even more tightly. The planets follow Kepler orbits fitted to NASA JPL's positions for 1 January 2026.
The 240,000 stars of the galaxy are drawn on the GPU. Each moves round the centre at the speed the same model gives for its distance, so the inner disc laps the outer one. The bright blue stars light up near two spiral arms that turn more slowly than the stars, the way density waves do. The arms are schematic: their shape and speed are typical values, not a map of the Milky Way's arms.