© Author(s) (or their employer(s)) 2018. Re-use permitted under CC BY. Published by BMJ. INTRODUCTION: Studies have demonstrated the existence of significant variation in test-ordering patterns in both primary and secondary care, for a wide variety of tests and across many health systems. Inconsistent practice could be explained by differing degrees of underuse and overuse of tests for diagnosis or monitoring. Underuse of appropriate tests may result in delayed or missed diagnoses; overuse may be an early step that can trigger a cascade of unnecessary intervention, as well as being a source of harm in itself. METHODS AND ANALYSIS: This realist review will seek to improve our understanding of how and why variation in laboratory test ordering comes about. A realist review is a theory-driven systematic review informed by a realist philosophy of science, seeking to produce useful theory that explains observed outcomes, in terms of relationships between important contexts and generative mechanisms.An initial explanatory theory will be developed in consultation with a stakeholder group and this 'programme theory' will be tested and refined against available secondary evidence, gathered via an iterative and purposive search process. This data will be analysed and synthesised according to realist principles, to produce a refined 'programme theory', explaining the contexts in which primary care doctors fail to order 'necessary' tests and/or order 'unnecessary' tests, and the mechanisms underlying these decisions. ETHICS AND DISSEMINATION: Ethical approval is not required for this review. A complete and transparent report will be produced in line with the RAMESES standards. The theory developed will be used to inform recommendations for the development of interventions designed to minimise 'inappropriate' testing. Our dissemination strategy will be informed by our stakeholders. A variety of outputs will be tailored to ensure relevance to policy-makers, primary care and pathology practitioners, and patients. PROSPERO REGISTRATION NUMBER: CRD42018091986.