Abstract. The spread of the new coronavirus SARS-CoV-2 that causes COVID-19 forced the Spanish Government to implement extensive lockdown measures to reduce the number of hospital admissions, starting on 14 March 2020. Over the following days and weeks, strong reductions in nitrogen dioxide (NO2) pollution were reported in many regions of Spain. A substantial part of these reductions was obviously due to decreased local and regional anthropogenic emissions. Yet, the confounding effect of meteorological variability hinders a reliable quantification of the lockdown's impact upon the observed pollution levels. Our study uses machine-learning (ML) models fed by meteorological data along with other time features to estimate the “business-as-usual” NO2 mixing ratios that would have been observed in the absence of the lockdown. We then quantify the so-called meteorology-normalized NO2 reductions induced by the lockdown measures by comparing the estimated business-as-usual values with the observed NO2 mixing ratios. We applied this analysis for a selection of urban background and traffic stations covering the more than 50 Spanish provinces and islands. The ML predictive models were found to perform remarkably well in most locations, with an overall bias, root mean square error and correlation of +4 %, 29 % and 0.86, respectively. During the period of study, from the enforcement of the state of alarm in Spain on 14 March to 23 April, we found the lockdown measures to be responsible for a 50 % reduction in NO2 levels on average over all provinces and islands. The lockdown in Spain has gone through several phases with different levels of severity with respect to mobility restrictions. As expected, the meteorology-normalized change in NO2 was found to be stronger during phase II (the most stringent phase) and phase III of the lockdown than during phase I. In the largest agglomerations, where both urban background and traffic stations were available, a stronger meteorology-normalized NO2 change is highlighted at traffic stations compared with urban background sites. Our results are consistent with foreseen (although still uncertain) changes in anthropogenic emissions induced by the lockdown. We also show the importance of taking the meteorological variability into account for accurately assessing the impact of the lockdown on NO2 levels, in particular at fine spatial and temporal scales. Meteorology-normalized estimates such as those presented here are crucial to reliably quantify the health implications of the lockdown due to reduced air pollution.