摘要:Background: Natural environments, including green spaces, may have beneficial impacts on brain development. However, longitudinal evidence of an association between long-term exposure to green spaces and cognitive development (including attention) in children is limited. Objectives: We evaluated the association between lifelong residential exposure to green space and attention during preschool and early primary school years. Methods: This longitudinal study was based on data from two well-established population-based birth cohorts in Spain. We assessed lifelong exposure to residential surrounding greenness and tree cover as the average of satellite-based normalized difference vegetation index and vegetation continuous fields, respectively, surrounding the child’s residential addresses at birth, 4–5 y, and 7 y. Attention was characterized using two computer-based tests: Conners’ Kiddie Continuous Performance Test (K-CPT) at 4–5 y ( n = 888) and Attentional Network Task (ANT) at 7 y ( n = 987). We used adjusted mixed effects models with cohort random effects to estimate associations between exposure to greenness and attention at ages 4–5 and 7 y. Results: Higher lifelong residential surrounding greenness was associated with fewer K-CPT omission errors and lower K-CPT hit reaction time-standard error (HRT-SE) at 4–5 y and lower ANT HRT-SE at 7 y, consistent with better attention. This exposure was not associated with K-CPT commission errors or with ANT omission or commission errors. Associations with residential surrounding tree cover also were close to the null, or were negative (for ANT HRT-SE) but not statistically significant. Conclusion: Exposure to residential surrounding greenness was associated with better scores on tests of attention at 4–5 y and 7 y of age in our longitudinal cohort. https://doi.org/10.1289/EHP694