The Cause

    Stars are large enough, and dense enough that without some force acting on it the star would collapse in on itself.  The action which provides this energy is nuclear fusion, which only occurs at incredibly high temperatures and pressure.  The intense heat provides a massive amount of kinetic energy to all of the particles inside the star.

Source (Atnf)

    Eventually though, the star starts to run out of fuel for nuclear fusion.  As nuclear fusion occurs lighter elements, mainly hydrogen and helium, get fused into heavier elements.  However these fusion reactions require elements lighter than iron for it to still be exothermal.  Since more mass doesn't enter a star very often, only the elements within can contribute to the reactions and they slowly turn into iron, meaning the fusion reactions start having less and less matter for the reactions.  As the reactions slow due to lower fuel supply, the stars internal energy also starts falling, eventually causing the internal forces which keep the star inflated to fail, which causes the star to start ejecting mass and then possibly go supernova at which point if the star was large enough there is a possibility of a black hole being born.