Exercise during growth may contribute to the prevention of osteoporosis by increasing peak bone mineral density (BMD). However, exercise during puberty may be associated with primary amenorrhea and low peak BMD, while exercise after puberty may be associated with secondary amenorrhea and bone loss. As growth before puberty is relatively sex hormone independent, are the prepubertal years the time during which exercise results in higher BMD? Are any benefits retained in adulthood? We measured areal BMD (g/cm²) by dual-energy X-ray absorptiometry in 45 active prepubertal female gymnasts aged 10.4 ± 0.3 years (mean ± SEM), 36 retired female gymnasts aged 25.0 ± 0.9 years, and 50 controls. The results were expressed as a standardized deviation (SD) or Z score adjusted for bone age in prepubertal gymnasts and chronological age in retired gymnasts. In the cross-sectional analyses, areal BMD in the active prepubertal gymnasts was 0.7–1.9 SD higher at the weight-bearing sites than the predicted mean in controls (p < 0.01). The Z scores increased as the duration of training increased (r = 0.32–0.48, p ranging between <0.04 and <0.002). During 12 months, the increase in areal BMD (g/cm²/year) of the total body, spine, and legs in the active prepubertal gymnasts was 30–85% greater than in prepubertal controls (all p < 0.05). In the retired gymnasts, the areal BMD was 0.5–1.5 SD higher than the predicted mean in controls at all sites, except the skull (p ranging between <0.06 and <0.0001). There was no diminution across the 20 years since retirement (mean 8 ± 1 years), despite the lower frequency and intensity of exercise. The prepubertal years are likely to be an opportune time for exercise to increase bone density. As residual benefits are maintained into adulthood, exercise before puberty may reduce fracture risk after menopause.