Which two things need to be perfect in order for petroleum to form?

In order for petroleum to form, two main factors need to be present:

1. Organic Material: A large amount of organic material, primarily in the form of dead marine organisms such as plankton and algae, is necessary. This organic material should be abundant, preserved from decay, and buried in an oxygen-depleted environment such as deep ocean sediments.

2. Heat and Pressure: Over millions of years, these organic materials are subjected to high heat and pressure as they are buried deeper and deeper beneath layers of sediment. This process, known as diagenesis and catagenesis, causes the organic material to undergo chemical changes, breaking down complex organic molecules into simpler hydrocarbon compounds, which form petroleum.

Both organic material and the right geological conditions, including heat and pressure, are essential for the formation of petroleum.