IntroductionVery preterm birth is associated with lung function impairment later in life, but several aspects have not been studied. We aimed to comprehensively assess lung function at school age in very preterm infants and term controls, with special emphasis on bronchopulmonary dysplasia (BPD), sex, and bronchodilator response.MethodsAt 12 years of age, 136 children born very preterm (85 with and 51 without BPD) and 56 children born at term performed spirometry, body plethysmography, impulse oscillometry, measurement of diffusion capacity, and multiple breath washout, before and after bronchodilator inhalation.ResultsAirway symptoms and a diagnosis of asthma were more common in children born very preterm. These children had more airflow limitation, seen as lower forced expiratory volume in 1 s (FEV1) (p < .001), FEV1/forced vital capacity (FVC) (p = .011), and mean forced expiratory flow between 25% and 75% of FVC (p < .001), and a higher total and peripheral airway resistance compared with term‐born controls. There was no difference in total lung capacity but air trapping and lung clearance index were higher in children born very preterm. Diffusion capacity was lower in children born very preterm, especially in those with a diagnosis of BPD. In most other tests, the differences between preterm‐born children with or without BPD were smaller than between children born preterm versus at term. Boys born preterm had more lung function deficits than preterm‐born girls. In children born very preterm, airway obstruction was to a large extent reversible.ConclusionAt 12 years of age, children born very preterm had lower lung function than children born at term in most aspects and there was only little difference between children with or without BPD. Airway obstruction improved markedly after bronchodilator inhalation.