The Groningen gas reservoir, situated in the northeast of the Netherlands, is western Europe’s largest producing gas field and has been in production since 1963. The gas production has induced both subsidence and seismicity. Seismicity is detected and located using the Koninklijk Nederlands Meteorologisch Instituut shallow-borehole array for the period 2015–2017, incorporating the back projection techniques of QuakeMigrate and the nonlinear location procedure to constrain earthquake locations and depths. The uncertainties on the estimated depths are estimated taking into account velocity model, changes in station array geometry and uncertainties in the measurement of arrival times of the P and S waves. We show that the depth distribution of seismicity is consistent with nucleation within the reservoir (28 per cent) or in the overburden (60 per cent) within ∼500 m from the top of the reservoir. Earthquakes with hypocentres in the overburden likely originate from overlying Zechstein anhydrite caprock. Based on their depth distribution, it seems like the earthquakes are primarily driven by the elastic strain in the reservoir and overburden, induced by the reservoir compaction. We estimate the probability of earthquakes nucleating beneath the reservoir in the underlying Carboniferous limestone and basement, to be no more than 12 per cent.