An unmet need exists for a non-invasive biomarker assay to aid gastric cancer diagnosis. We aimed to develop a serum microRNA (miRNA) panel for identifying patients with all stages of gastric cancer from a high-risk population.We conducted a three-phase, multicentre study comprising 5248 subjects from Singapore and Korea. Biomarker discovery and verification phases were done through comprehensive serum miRNA profiling and multivariant analysis of 578 miRNA candidates in retrospective cohorts of 682 subjects. A clinical assay was developed and validated in a prospective cohort of 4566 symptomatic subjects who underwent endoscopy. Assay performance was confirmed with histological diagnosis and compared with Helicobacter pylori (HP) serology, serum pepsinogens (PGs), 'ABC' method, carcinoembryonic antigen (CEA) and cancer antigen 19-9 (CA19-9). Cost-effectiveness was analysed using a Markov decision model.We developed a clinical assay for detection of gastric cancer based on a 12-miRNA biomarker panel. The 12-miRNA panel had area under the curve (AUC)=0.93 (95% CI 0.90 to 0.95) and AUC=0.92 (95% CI 0.88 to 0.96) in the discovery and verification cohorts, respectively. In the prospective study, overall sensitivity was 87.0% (95% CI 79.4% to 92.5%) at specificity of 68.4% (95% CI 67.0% to 69.8%). AUC was 0.848 (95% CI 0.81 to 0.88), higher than HP serology (0.635), PG 1/2 ratio (0.641), PG index (0.576), ABC method (0.647), CEA (0.576) and CA19-9 (0.595). The number needed to screen is 489 annually. It is cost-effective for mass screening relative to current practice (incremental cost-effectiveness ratio=US$44 531/quality-of-life year).We developed and validated a serum 12-miRNA biomarker assay, which may be a cost-effective risk assessment for gastric cancer.This study is registered with ClinicalTrials.gov (Registration number: NCT04329299).