Petroleum oil (and natural gas) was formed by the decomposition of the remains of extremely small plants and animals buried under the sea millions of years ago. It is believed that millions of years ago, the microscopic plants and animals which lived in seas, died. Their bodies sank to the bottom of the sea and were soon covered with mud and sand. The chemical effects of pressure, heat and bacteria, converted the remains of microscopic plants and animals into petroleum oil and natural gas just as they converted forest trees into coal. This conversion took place in the absence of oxygen or air. The petroleum thus formed got trapped between two layers of impervious rocks (non-porous rocks) forming an oil trap.