Evidence on the association between early-life malnutrition exposure at different developmental stages and the subsequent risk of osteoporosis and fractures in adulthood remains sparse and equivocal. This study sought to elucidate the relationship between malnutrition exposure in early life and the occurrence of osteoporosis and fractures later in life. This research is a cross-sectional analysis carried out within the framework of the China Community-based Cohort of Osteoporosis (CCCO), an ongoing community-based cohort study. Participants were stratified by birthdate into several categories: non-exposed, fetal, early childhood, mid-childhood, late childhood, and adolescence exposure groups. The non-exposure and adolescence exposure groups were consolidated into an "age-matched group" to provide a robust comparative framework for analyzing the probability of developing osteoporosis (defined as a T-score ≤ -2.5 in bone mineral density) and the frequency of self-reported fracture. Multiple logistic regression models were utilized to investigate the association between early-life malnutrition exposure and the risks of osteoporosis and fracture. Additionally, we validated our findings using the China Northwest Cohort (CNC). A total of 12,789 participants were included into the final analysis. After adjusting for various covariates, individuals exposed to malnutrition during their fetal and childhood stages (early, middle, and late) increased the likelihood of developing osteoporosis in adulthood, compared to their age-matched counterparts. In these four groups, the ORs (95% CI) for osteoporosis risk were 1.223 (1.035 to 1.445), 1.208 (1.052 to 1.386), 1.249 (1.097 to 1.421), and 1.101 (1.001 to 1.210), respectively (all P values < 0.05). Specifically, the late childhood exposure group showed a heightened risk of fracture, with an OR (95% CI) of 1.155 (1.033 to 1.291) and a P-value of 0.01127. Stratified analyses further found a significant correlation between early-life exposure to malnutrition and an elevated risk of osteoporosis in participants with lower educational attainment, overweight or obese participants. Additionally, corroborating evidence from the CNC confirmed the influence of malnutrition exposure on osteoporosis risk. Early-life exposure to malnutrition had a detrimental impact on bone health. Individuals who had experienced malnutrition during fetal and childhood stages (early, middle, and late) exhibited a high susceptibility to osteoporosis in adulthood, compared to age-matched cohorts. This susceptibility was particularly pronounced in women, and individuals who were overweight or obese, or had lower levels of education.