BackgroundAdolescence represents a crucial developmental period in shaping mental health trajectories. In this study, we investigated the effect of the COVID-19 pandemic on mental health and substance use during this sensitive developmental stage.MethodsIn this longitudinal, population-based study, surveys were administered to a nationwide sample of 13–18-year-olds in Iceland in October or February in 2016 and 2018, and in October, 2020 (during the COVID-19 pandemic). The surveys assessed depressive symptoms with the Symptom Checklist-90, mental wellbeing with the Short Warwick Edinburgh Mental Wellbeing Scale, and the frequency of cigarette smoking, e-cigarette use, and alcohol intoxication. Demographic data were collected, which included language spoken at home although not ethnicity data. We used mixed effects models to study the effect of gender, age, and survey year on trends in mental health outcomes.Findings59 701 survey responses were included; response rates ranged from 63% to 86%. An increase in depressive symptoms (β 0·57, 95% CI 0·53 to 0·60) and worsened mental wellbeing (β −0·46, 95% CI −0·49 to −0·42) were observed across all age groups during the pandemic compared with same-aged peers before COVID-19. These outcomes were significantly worse in adolescent girls compared with boys (β 4·16, 95% CI 4·05 to 4·28, and β −1·13, 95% CI −1·23 to −1·03, respectively). Cigarette smoking (OR 2·61, 95% CI 2·59 to 2·66), e-cigarette use (OR 2·61, 95% CI 2·59 to 2·64), and alcohol intoxication (OR 2·59, 95% CI 2·56 to 2·64) declined among 15–18-year-olds during COVID-19, with no similar gender differences.InterpretationOur results suggest that COVID-19 has significantly impaired adolescent mental health. However, the decrease observed in substance use during the pandemic might be an unintended benefit of isolation, and might serve as a protective factor against future substance use disorders and dependence. Population-level prevention efforts, especially for girls, are warranted.FundingIcelandic Research Fund.TranslationFor the Icelandic translation of the abstract see Supplementary Materials section.