Petroleum was formed from organisms living in the sea. As these organisms died, their bodies settled at the bottom of the sea and got covered with layers of sand and clay. Over Millions of years in absence of air and under high temperature and high pressure the dead organisms get transformed into Petroleum and natural Gas.