Maternal nutrition is essential in fetal development; thus, disordered eating may influence this process and contribute to the development of offspring psychiatric disorders. To investigate the association of maternal eating disorders and prepregnancy body mass index (BMI) with offspring psychiatric diagnoses. This population-based cohort study used Finnish national registers to assess all live births from January 1, 2004, through December 31, 2014, with follow-up until December 31, 2021. The data analyses were conducted from September 1, 2023, to September 30, 2024. Maternal eating disorder and prepregnancy BMI. Primary outcomes were 9 neurodevelopmental and psychiatric offspring diagnoses. Cox proportional hazards modeling adjusted for potential risk factors in the development of the outcome disorders was applied in 2 models. Secondary analyses were stratified for adverse birth outcomes (prematurity, small size for gestational age, and low Apgar score) or comorbid offspring eating disorders. Categories of BMI (calculated as weight in kilograms divided by height in meters squared) included underweight (BMI <18.5), normal weight (18.5-24.9), overweight (25.0-29.9), obesity (30.0-34.9), and severe obesity (≥35.0). The mean (SD) age of 392 098 included mothers was 30.15 (5.38) years, 42 590 mothers (10.86%) were born outside of Finland, 6273 mothers (1.60%) had a history of an eating disorder, 23 114 mothers (5.89%) had prepregnancy underweight, and 208 335 (53.13%) mothers had overweight or obesity. Among 649 956 included offspring, 332 359 (51.14%) were male, and 106 777 (16.43%) had received a neurodevelopmental or psychiatric diagnosis. Maternal eating disorders, prepregnancy underweight, and overweight or obesity were associated with most of the studied mental diagnoses in offspring, even after adjusting for potential covariates. The largest effect sizes were observed for maternal eating disorders not otherwise specified in association with offspring sleep disorders (hazard ratio [HR], 3.34 [95% CI, 2.39-4.67]) and social functioning and tic disorders (HR, 2.79 [95% CI, 2.21-3.52]), while for maternal severe prepregnancy obesity, offspring intellectual disabilities (HR, 2.04 [95% CI, 1.83-2.28]) had the largest effect size. Adverse birth outcomes further increased the risk of offspring having other feeding disturbances of childhood and infancy (eg, HR, 4.53 [95% CI, 2.97-6.89] for maternal eating disorders) and attention-deficit/hyperactivity disorder and conduct disorder (eg, HR, 2.27 [95% CI, 1.74-2.96] for maternal anorexia nervosa). In this population-based cohort study including 392 098 mothers and 649 956 offspring, offspring from mothers with an eating disorder history or prepregnancy BMI outside normal weight were at higher risk of psychiatric disorders. The results differed somewhat between the 2 exposures with regard to which offspring diagnoses had associations, and effect sizes were typically larger for maternal eating disorders vs BMI. These findings suggest a need to consider these 2 exposures clinically to help prevent offspring mental illness.