The light and heat from stars is made by a process called nuclear fusion.
Fusion happens when 2 atoms are forced together to form a heavier atom. This creates a lot of energy. However, fusion can only occur at the incredibly high temperatures and pressures found in the centre of stars.
All the elements in the Universe heavier than hydrogen and helium were made in stars through nuclear fusion. When the star dies these elements are then emitted into space. They move into nearby gas clouds, or nebula, and form the building blocks for a new generation of stars.
Our Sun and all the planets in the Solar System, contain these elements. Elements produced inside the very first stars. This means that you, and everything around you, is also made of "stardust".
Scientists on Earth are trying to find a way to make nuclear fusion power stations. These would be much cleaner than current nuclear fission power stations. They would also produce a lot of energy. But it is really hard to do on Earth because you have to make conditions like we have inside stars. You need to make the gas in the machines very hot and with a high pressure.