Here's why:
* The Sun's Energy Source: The sun produces energy through nuclear fusion, where hydrogen atoms fuse to form helium. This process releases a tremendous amount of energy.
* Hydrogen Depletion: Over billions of years, the hydrogen in the sun's core is gradually consumed. Eventually, the core will be mostly helium.
* Core Contraction: Without the outward pressure from fusion, the core begins to contract under its own gravity.
* Heating and Expansion: This contraction heats the core to even higher temperatures. The outer layers of the sun will expand enormously, engulfing Mercury, Venus, and potentially even Earth. This is the "red giant" phase.
* Final Stages: After the red giant phase, the sun will eventually shed its outer layers, leaving behind a small, dense core called a white dwarf. The white dwarf will slowly cool and fade over billions of years.
So, the sun won't run out of its core, but it will run out of the fuel that powers its core. This will lead to a series of dramatic changes, culminating in its transformation into a red giant.