Final answer:
The energy contained in fossil fuels originated from the Sun, captured through the photosynthesis of ancient plants and converted into chemical energy over millions of years.
Step-by-step explanation:
The origin of the energy contained in fossil fuels is the Sun. Fossil fuels such as coal, oil, and natural gas, were formed from the biological material of dead plants and animals. These organisms originally captured the Sun's energy through photosynthesis, converting it into chemical energy that was stored in their tissues. Over millions of years, the remains of these organisms were buried, heated, and compressed under high pressure, transforming the biomass into fossil fuels. Therefore, fossil fuels are essentially a form of long-term storage of solar energy, with an energy density far greater than many other forms of storage like batteries or hydroelectric reservoirs.