Solar System
Helix Nebula  

The death of stars is dramatic and climactic. Stars can die either as a planetary nebula or a supernova explosion. Small or medium sized stars become planetary nebulae and large stars such as blue and red giants explode as supernovae. A star called Eta Carinae might explode as a hypernova. The remains of small stars would be tiny white dwarfs. The remains of large stars would be left behind as neutron stars and these can collapse to become black holes, regions where gravity is so strong that even light can't escape.

Dying stars contain heavy elements, which are used in star formation and these heavy elements are used to make planets. So essentially there is a bit of stardust in everyone!

The Helix Nebula is a very close planetary nebula at 450 light years away. The actual shape isn't spherical and the nebula structure consists of many overlapping shells and rings that were discovered by the Hubble Space Telescope.  
Image copyright R. Gendler

Planetary nebulae, as the name suggests are completely unrelated to planets. The name comes from 18th century skywatchers who thought they looked like planets in the small telescopes that were available then.

They are created when a small sized star's hydrogen fuel runs out and becomes a white dwarf. The other gases inside the star are expelled in concentric shells and surround the white dwarf. Surprisingly white dwarfs are very hot but they are fainter than the surrounding planetary nebula. The gases inside planetary nebulae are constantly expanding outwards at very fast speeds although there are no noticeable differences apparent in their appearances after a few decades. Altogether there are 1500 planetary nebulae in the Milky Way, which is quite low compared to the number of stars. Overall they only last for a few thousand years.

Witch's Broom Nebula    
The Witch's Broom Nebula is part of the much larger Veil Nebula supernova remnant. It is about 10 000 years old. It contains oxygen, sulphur and hydrogen.    
Image copyright R. Croman

Supernovae are titanic explosions that happen when large stars die. They happen very infrequently and the last supernova in the Milky Way was in 1604. They are so bright that when they first explode,they can be seen during the day for a few months. They also release the same amount of energy as a star would during 10 billion years!

A supernova explosion is so destructive that it is more powerful than a thousand nuclear bombs. It causes all the material inside a star to be expelled at a supermassive speed. This causes a shockwave to collide into a wall of gas and dust and this forms a supernova remnant.

An incongruous role of supernovae is to plant the seeds of life inside nearby molecular clouds. Energy from the supernova remnant causes the compression of dust clouds and this initiates star formation.

Neutron stars are one of two further stages. It contains a type of particle called the neutron. Neutron stars are so dense that a tiny spoonful would weigh one billion tons! They also have magnetic fields that are a million times stronger than ones around planets. Strangely, some neutron stars have orbiting planets.

A variant of neutron stars are pulsars, the first was discovered in 1967 in the Crab Nebula supernova. Basically pulsars are neutron stars that spin very rapidly and create jets of light.

Black holes are the second endpoint of the life of a giant star. They are created when a large star collapses under its gravity. They are called black holes because they can't be seen but they are detected by their interaction with their surroundings. Galaxies have supermassive black holes at the centre and what stops the entire galaxy being sucked in is that they only suck in what is close to the black hole. Black holes don't last forever and evaporate after a certain amount of time. This was discovered by Stephen Hawking. Also black holes can collide with each other and they merge into one single entity. This merger generates a tremendously high amount of energy.