BACKGROUND: Brain-derived neurotrophic factor levels are higher in those who are physically active and lower in people with cognitive dysfunction. This study investigated whether brain-derived neurotrophic factor mediated or modified the association of sedentary time to MRI-estimated brain volumes in midlife. METHODS: Baseline (n = 612) and five-year follow-up (n = 418) data were drawn from the multicenter Coronary Artery Risk Development in Young Adults Brain MRI sub-study, including Black and White participants (aged 50.3 years, 51.6% females, 38.6% Black). Sedentary time (hours per day) was categorized into quartiles with low ≤ 4.3 (reference) and high > 8.4. Outcomes of the study were total brain, white matter, gray matter, hippocampal volumes, and white matter fractional anisotropy at baseline and 5-year percent change from baseline. The study used general linear regression models to examine the mediation and moderation effects of brain-derived neurotrophic factor (natural log transformed) on the associations of sedentary time to brain outcomes. The authors adjusted the regression model for age, sex, race, intracranial volume, education, and vascular factors. RESULTS: Cross-sectionally, baseline participants with the highest sedentary time had a lower total brain (-12.2 cc; 95%CI: -20.7, -3.7), gray matter (-7.8 cc; 95%CI: -14.3, -1.3), and hippocampal volume (-0.2 cc; 95%CI: -0.3, 0.0) compared with populations with the lowest sedentary time. The brain-derived neurotrophic factor levels did not mediate the associations between brain measures and sedentary time. Brain-derived neurotrophic factor was found to moderate associations of sedentary time to total brain and white matter volume such that the brain volume difference between high and low sedentary time decreased as brain-derived neurotrophic factor levels increased. Longitudinally, higher baseline brain-derived neurotrophic factor level was associated with less brain volume decline. The longitudinal associations did not differ by sedentary time, and brain-derived neurotrophic factor did not mediate or moderate the association of sedentary time to brain measure changes. CONCLUSIONS: Higher brain-derived neurotrophic factor levels may buffer the negative effects of sedentary time on the brain.