A star balances the inward pull of the gravity generated by its mass with the outward pressure generated by fusion reactions in its core. When all the available fuel is exhausted, fusion stops, gravity triumphs and the core collapses. What happens after that depends on how much mass the doomed star had in the first place. For stars with between about 10 and 25 solar masses, the end result is a neutron star with about 1.4 times the mass of the Sun crammed into am unimaginably dense city-size sphere. The cores of heavier stars can collapse past the neutron star stage, becoming black holes and effectively dropping out of the known universe. For stars like the Sun, the outer atmosphere is blown out into space while the core shrinks down to the size of a terrestrial planet. The result is a white dwarf. This image of NGC 2440, captured by the Hubble Space Telescope in 2007, shows a brilliant, extremely hot white dwarf shining in the centre of expanding clouds of gas from the doomed star’s blown-off outer atmosphere. Ultraviolet light from the white dwarf, one of the hottest known, makes the gas in the so-called planetary nebula glow.
The NASA/ESA Hubble Space Telescope has detected superhot blobs of gas, each twice as massive as the planet Mars, being ejected near a dying red giant star in the V Hydrae binary system. The plasma balls are zooming so fast through space it would take only 30 minutes for them to travel from Earth to the Moon.
While truly massive stars go out in a blaze of glory, intermediate-mass stars — those between roughly one and eight times the mass of the Sun — are somewhat quieter. Such stars eventually form cosmic objects known as planetary nebulae, so named because of their vague resemblance to planets when seen through early, low-resolution telescopes.