The core of the sun is so hot and there is so much pressure, nuclear fusion takes place: hydrogen is changed to helium. Nuclear fusion creates heat and photons (light).
The sun's surface is about 6,000 Kelvin, which is 10,340 degrees Fahrenheit (5,726 degrees Celsius). The amount of solar heat and light is enough to light up Earth's days and keep our planet warm enough to support life.
SpaceKids on SPACE.com provides simple, straightforward answers to really big cosmic questions. See more SpaceKids questions.