BackgroundThe misuse of psychotropic medication has increased during the past decade, especially among adolescents. The aim of our study was to describe the prevalence and patterns of the nonmedical use of benzodiazepines (BDZ) and Z‐hypnotics among school‐aged adolescents through the lens of sex. In addition, we sought to analyze the temporal evolution of the nonmedical use of these drugs during the period 2016–2021.MethodsThe temporal evolution of the nonmedical use of these drugs was analyzed based on survey data collected in 2016, 2018 and 2021, which includes the first years of the COVID‐19 pandemic. To assess the possible effect of the COVID‐19 pandemic, the year at survey was conducted was introduced as a categorical variable. We used data from the Spanish State Survey on Drug Use in Secondary Education, which covers drug use among students aged 14–18 years. Using multivariate logistic regression models, we estimated the independent effect of different variables (sociodemographic data, use of other psychoactive substances, risk perception and availability) on the nonmedical use of BDZ and Z‐hypnotics.ResultsIn total, survey data from 95,700 adolescents were included in our analysis. The nonmedical use of BDZ and Z‐hypnotics increased among adolescents during the study period. The adjusted odds ratio (AOR) from 2016 to 2018 was 1.11 (95% CI 0.94–1.31) and from 2018 to 2021 the AOR was 1.26 (95% CI 1.08–1.46), using 2016 and 2018, respectively, as reference years. The nonmedical use of BDZ and Z‐hypnotics was more likely in adolescent girls than boys (AOR = 2.11). The nonmedical use of prescription opioids (AOR = 3.44), novel psychoactive substances and other illicit psychoactive drugs (AOR = 4.10) were risk factors for the nonmedical use of BDZ and Z‐hypnotics in both sexes. Use of cannabis (AOR = 1.38) was a predictor of nonmedical use in female adolescents only.ConclusionsThis study shows that the trend of the nonmedical use of BDZ and Z‐hypnotics among school‐aged adolescents in Spain increased between 2016 and 2021. Among adolescents aged 14 to 18, the probability of nonmedical use of these psychoactive substances was twice as high for female adolescents as for male adolescents.