Substance use, depression, and anxiety in adolescence are major public health problems requiring new scalable prevention strategies. We aimed to assess the effectiveness of a combined online universal (ie, delivered to all pupils) school-based preventive intervention targeting substance use, depression, and anxiety in adolescence. We did a multicentre, cluster-randomised controlled trial in secondary schools in Australia, with pupils in year 8 or 9 (aged 13-14 years). Participating schools were randomly assigned (1:1:1:1) to one of four intervention conditions: (1) Climate Schools-Substance Use, focusing on substance use only; (2) Climate Schools-Mental Health, focusing on depression and anxiety only; (3) Climate Schools-Combined, focusing on the prevention of substance use, depression, and anxiety; or (4) active control. The interventions were delivered in school classrooms in an online delivery format and used a mixture of peer cartoon storyboards and classroom activities that were focused on alcohol, cannabis, anxiety, and depression. The interventions were delivered for 2 years and primary outcomes were knowledge related to alcohol, cannabis, and mental health; alcohol use, including heavy episodic drinking; and depression and anxiety symptoms at 12, 24, and 30 months after baseline. This trial is registered with the Australian New Zealand Clinical Trials Registry (ACTRN12613000723785) and an extended follow-up is underway. Between Sept 1, 2013, and Feb 28, 2014, we recruited 88 schools (12 391 pupils), of whom 71 schools and 6386 (51·5%) pupils were analysed (17 schools dropped out and 1308 pupils declined to participate). We allocated 18 schools (1739 [27·25%] pupils; 1690 [97·2%] completed at least one follow-up) to the substance use condition, 18 schools (1594 [25·0%] pupils; 1560 [97·9%] completed at least one follow-up) to the mental health condition, 16 schools (1497 [23·4%] pupils; 1443 [96·4%] completed at least one follow-up) to the combined condition, and 19 schools (1556 [23·4%] pupils; 1513 [97·2%] completed at least one follow-up) to the control condition. Compared with controls, the combined intervention group had increased knowledge related to alcohol and cannabis at 12, 24, and 30 months (standardised mean difference [SMD] for alcohol 0·26 [95% CI 0·14 to 0·39] and for cannabis 0·17 [0·06 to 0·28] at 30 months), increased knowledge related to mental health at 24 months (0·17 [0·08 to 0·27]), reduced growth in their odds of drinking and heavy episodic drinking at 12, 24, and 30 months (odds ratio for drinking 0·25 [95% CI 0·12 to 0·51], and for heavy episodic drinking 0·15 [0·04 to 0·58] at 30 months), and reduced increases in anxiety symptoms at 12 and 30 months (SMD -0·12 [95% CI -0·22 to -0·01] at 30 months). We found no difference in symptoms or probable diagnosis of depression. The combined intervention group also showed improvement in alcohol use outcomes compared with the substance use and mental health interventions and improvements in anxiety outcomes when compared with the mental health intervention only. Combined online prevention of substance use, depression, and anxiety led to increased knowledge of alcohol, cannabis, and mental health, reduced increase in the odds of any drinking and heavy episodic drinking, and reduced symptoms of anxiety over a 30-month period. These findings provide the first evidence of the effectiveness of an online universal school-based preventive intervention targeting substance use, depression, and anxiety in adolescence. Australian National Health and Medical Research Council.