Maternal nutrition during gestation has been investigated for its role in child neurodevelopment. However, little is known about the potential impact of gestational caffeine exposure on child autistic behaviors. Here, we assess the relation between maternal caffeine intake during pregnancy and children’s behavioral traits related to Autism Spectrum Disorder (ASD). We harmonized data from two pregnancy cohorts, Early Autism Risk Longitudinal Investigation (EARLI) (n = 120), an enriched-risk cohort of mothers who previously had a child with ASD, from Pennsylvania, Maryland, and Northern California (2009–2012), and the Health Outcomes and Measures of the Environment (HOME) Study (n = 269), a general population cohort from Cincinnati, Ohio (2003–2006). Mothers self-reported caffeine intake twice during pregnancy. Caregivers reported child behavioral traits related to ASD using the Social Responsiveness Scale (SRS) when children were aged 3–8 years. Higher scores indicate more ASD-related behaviors. We estimated covariate-adjusted differences in continuous SRS T-scores per interquartile range increase in caffeine intake. Self-reported caffeine intake during pregnancy was positively associated with SRS T-scores among children in EARLI (β: 2.0; 95% CI -0.1, 4.0), but to a lesser extent in HOME (β: 0.6; 95% CI -0.5, 1.6). In HOME, pre-pregnancy body mass index (BMI) modified the association between caffeine intake and SRS T-scores, where more positive associations were observed among women with higher BMIs. Our findings suggest gestational caffeine intake may represent a marker of vulnerability to childhood ASD-related behaviors. Additional studies are warranted to extend these findings.