Oil in the Jarvis structure underlying the main Upper Jurassic reservoir at the Ettrick oilfield (Outer Moray Firth, UK northern North Sea) is present in Upper Permian (Zechstein) carbonates. The origin of this "Jarvis oil" is investigated in this paper using a multidisciplinary approach based on data from well-logs and cores from wells 20/02-2 and 20/02-3. Reservoirs at the Jarvis structure consist of carbonates in the upper part of the Halibut Carbonate Formation (Ca2) and in the Carbonate Member of the Turbot Anhydrite Formation (Ca3). These carbonates are typical Zechstein dolomites composed of a range of facies from mudpackstones with storm beds deposited at moderate water depths to shoreface bioclastic-oolitic packstones to shallow-subtidal and intertidal microbial laminites. Interbedded anhydrites replace sabkha and lagoonal selenitic gypsum. Several shallowing-upward units are recognised. Molecular analysis of the Jarvis oil, and comparisons with biomarker and other geochemical data from extracts of Zechstein cores and published data from different source rocks from the North Sea area, suggest that the oil was generated by marine, OM-rich shales in the Upper Jurassic Kimmeridge Clay Formation. The oil was generated at peak oil window maturity and is characterised by high Pr/Ph, BNH/H and DBT/P ratios, and abundant C 28 steranes and C 28+29 monoaromatic and C 26 R + C 27 S triaromatic steroids. The molecular composition of organic material in extracts of core samples of Zechstein carbonates from wells in the Jarvis structure differs significantly from that of the Jarvis oil. Biomarkers such as BNH are absent in the core extracts, and there are different distributions and abundances of saturated and aromatic hydrocarbons, likely controlled by thermal maturity.