This is where a new star is born: in a cloud of gas called a nebula.
The gas and dust inside will eventually start to fuse together, forming a protostar, and then a main sequence star.
The nuclear reactions inside the star produce energy which in turn emits light. Our sun is in the main sequence currently.
The stars will continue to use this energy until they run out of fuel; however, this will not happen until billions of years later.
The stars will continue to use this energy until they run out of fuel; however, this will not happen until billions of years later.
When the stars are running out of fuel, it begins to start to expand and become a red giant
When the red giant finally runs out of fuel, it will cool down and stop glowing. It's at this time that it's outer layers shed off and become a planetary nebula.
It's at this point that the outer layers leave behind a very dense and hot white core called a white dwarf. It will eventually become a nuetron star.