A fossil fuel is a type of fuel that is formed over millions of years from the remains of dead plants and animals. One example of a fossil fuel is coal, which is formed from the remains of ancient plants that lived millions of years ago. As these plants died and were buried under layers of sediment, they were compressed and heated over time, which transformed them into coal. Other examples of fossil fuels include oil and natural gas, which are formed in a similar way from the remains of marine organisms that lived millions of years ago. Granite and sandstone are types of rocks that are not considered to be fossil fuels.