Pediatric headache patients often experience significant sleep disturbance, which may be a risk factor for poor physical, academic, and emotional functioning, including increased anxiety/fear. The current retrospective cohort study of a clinical sample of youth with persistent headache aimed to examine the impact of sleep on functional outcomes and to explore pain-related fear as a mediator of the association between sleep problems and functioning. A total of 109 youth (aged 7-17 years) with persistent headache presenting to a tertiary pediatric headache center (and their parents) completed measures of sleep problems, fear of pain, functional disability, and school functioning at the time of an initial evaluation and 6 months later. After controlling for age and headache frequency and severity, linear regression analyses indicated that increased sleep problems at baseline were associated with increased functional disability and poorer school functioning at baseline ( = 0.28, = .01; = -0.42, < .001, respectively). Poor sleep at baseline was associated with poorer school functioning (but not functional disability) at follow-up ( = -0.25, = .02). Mediation models demonstrated an indirect mediating effect of pain-related fear on the association between baseline sleep problems and follow-up functional disability ( = 0.06, 95% confidence interval 0.01, 0.15) and between baseline sleep problems and follow-up school functioning ( = -0.06, 95% confidence interval -0.13, -0.004). Sleep disturbance in youth with headache may be a risk factor for poor functional outcomes, both concurrently and over time, and may be explained partially through pain-related fear. Given the frequency with which pediatric headache patients experience co-occurring sleep problems, sleep should be thoroughly assessed and considered as a potential early treatment target.