A balanced diet in childhood is important for growth and development. We aimed to examine associations of overall diet quality in both early and mid-childhood with trajectories of growth and body composition until age 10 years.We included 3991 children from the Generation R Study, a population-based, prospective cohort in Rotterdam, the Netherlands. At child's ages of 1 and 8 years, dietary intake was assessed using food-frequency questionnaires to calculate diet quality scores (0-10), which measure adherence to age-specific dietary guidelines. Height and weight were measured repeatedly between ages 1 and 10 years. Body composition was assessed using dual-energy X-ray absorptiometry at ages 6 and 10 years. We calculated sex- and age-specific SD-scores for body mass index (BMI), fat mass index (FMI), fat-free mass index (FFMI), and body fat percentage (BF%).After adjustment for socioeconomic and lifestyle factors, results from linear mixed models showed that higher diet quality at 1 year was associated with higher height, weight, and BMI up to age 10 years. Using linear regression analyses, similar associations were observed for diet quality at 8 years. For diet quality at both time points, positive associations with BMI were fully driven by a higher FFMI (β = 0.07 SDS, 95%CI: 0.05, 0.10 for diet quality at 8 years), and not FMI or BF%. Most of the observed associations were independent of diet quality at the other time point.We observed that better diet quality in both early and mid-childhood was associated with higher height, weight, and FFMI, but not with body fatness up to age 10 years. This was independent of diet quality at an earlier or later time point. Our findings suggest that dietary intake according to dietary guidelines may have a beneficial impact on growth and body composition throughout childhood.