A supernova is formed when the fuel at the centre runs out. Basically you form an iron core, through fusion. This is the most stable element so you can't get any more binding energy out of it. With no power, the star collapses under it's own weight, and becomes dense so that the outer layers bounce off the inner core, exploding outwards as a supernova. What's left will either form a neutron star or a black hole, depending on the mass.
and technically this isn't cosmology, it's astrophysics