How does a supernova form?
When nuclear fusion stops.
When the nuclear fusion of a massive star stops, it means that all of its core is mainly Iron. Then the iron atom, instead of releasing energy, it absorbs it. After a while, the energy absorbed will be released and causes an explosion called a supernova