In general, hydrocarbons are not formed in the rock formations from which they are produced (except for biogenous gas). They are generated in the so-called source rock. Due to density differences with water, hydrocarbons start to migrate. During migration they are either caught in “traps” (reservoir rock) and form reservoirs or they travel up to the surface where they evaporate.
In an oil reservoir, crude oil always is located above a water-bearing zone (aquifer). On top of it, a gas cap may accumulate. In gas reservoirs the oil-bearing zone is missing– the gas is accumulated directly above the aquifer.
Hydrocarbons accumulate in pores of the reservoir rock, similar to a sponge soaked with water. The volume available to hydrocarbons is called pore space and covers about one fifth of the reservoir rock.
The percentage of hydrocarbons recovered during production without artificial lift may amount to 30% of hydrocarbons initially in an oil reservoir and up to 90% in gas reservoirs. If oil and gas are produced from a reservoir, the pore space is filled with rising water.