The spatial distribution of oil is determined by natural geography alone. However, we show that the distribution of oil exploration is affected by the quality of countries’ institutions. A global data set on the precise location of oil wells and national borders allows for a regression discontinuity design and causal inference. Crossing a national border, moving from the average worse to average better institutional quality, generates a positive jump in the predicted number of wells by 150% in the sample of developing countries. Correspondingly, a one standard deviation increase in institutional quality increases the likelihood of drilling by about 250%. The findings underscore that proved oil reserves are an endogenous economic outcome and lend support to the hypothesis that institutions are a fundamental determinant of economic performance.