Fossil fuels are a non-renewable energy source formed from the remains of ancient plants and animals. There are three main types: coal, petroleum, and natural gas. Coal forms from dead plant matter subjected to heat and pressure over millions of years. Oil forms from decayed plants and algae and is extracted through drilling. Natural gas forms from decayed organisms and is extracted as bubbles trapped underground. Fossil fuels undergo processing and refining before use as energy sources.