In utero exposure to maternal cancer and cancer treatment might influence the child's short- and long-term health and development. The objective of the study was to investigate short- and long-term somatic and psychiatric outcomes in children exposed to maternal cancer in utero. This nationwide cohort study identified all liveborn children in Denmark between January 1978 and December 2018. Exposure was defined as maternal cancer diagnosis during pregnancy, and in a subgroup analysis, exposure to chemotherapy in utero. The main outcomes of interest were overall mortality, somatic diagnoses, and psychiatric diagnoses identified in the National Health Registers. Follow-up started at birth and ended at an event, death, emigration, or end of 2018. Hazard ratios of end points adjusted for potential confounders were estimated using Cox regression analysis. Of 2,526,163 included liveborn children, 690 (0.03%) were exposed to maternal cancer in utero. Compared with unexposed fetuses, children exposed in utero had no higher overall mortality, adjusted hazard ratio 0.8 (95% CI, 0.4 to 1.5), nor increased risk of congenital malformations, overall somatic or psychiatric disease. During the period 2002-2018, of 378 (0.03%) children exposed to cancer in utero, 42 (12.5%) were exposed to chemotherapy. Among these 42 children, in utero exposure to chemotherapy was not associated with selected somatic diseases nor to congenital malformations when compared with in utero exposure to maternal cancer without chemotherapy. Overall, findings did not indicate excess risk of mortality or severe morbidity among children exposed to cancer in utero. Fetal exposure to chemotherapy was not associated with adverse health outcomes in childhood.