Weight extremes and food insecurity (FIS) represent public-health challenges, yet their associations in childhood remain unclear. We aimed to investigate the longitudinal time-specific relationship between FIS and risk of overweight/obesity and underweight in kindergarten through 8th grade. In the prospective Early Childhood Longitudinal Study-Kindergarten Cohort (1998-2007) of 6368 children, household FIS was assessed by the validated US Household Food Security Survey Module in kindergarten, 3rd, 5th and 8th grades. Multivariable linear-regression and Poisson-regression models were computed. Compared with children experiencing food security (FS), children exposed to FIS in 5th grade had 0.19 [95% confidence interval (CI): 0.07-0.30] and 0.17 (0.06-0.27) higher body mass index z-score (BMIZ) in the 5th and 8th grades, respectively, whereas FIS in the 8th grade was associated with a 0.29 (0.19-0.40) higher BMIZ at the same wave, after adjusting for covariates and FIS at earlier waves. Children with FIS vs FS had 27% (relative risk: 1.27, 95% CI: 1.07-1.51), 21% (1.21, 1.08-1.35) and 28% (1.28, 1.07-1.53) higher risk of overweight/obesity in the 3rd, 5th and 8th grades, respectively, adjusting for covariates and FIS at prior wave(s). Children with FIS vs FS in kindergarten had a 2.76-fold (1.22-6.25) higher risk of underweight in the 8th grade. Proximal exposure to household FIS was associated with a higher risk of overweight/obesity in the 3rd, 5th and 8th grades. FIS in kindergarten was associated with a risk of underweight in the 8th grade. Thus, FIS coexists in weight extremes during vulnerable early-life windows in the USA, similarly to the global burden of FIS. © The Author(s) 2019; all rights reserved. Published by Oxford University Press on behalf of the International Epidemiological Association.