We retrospectively compared the costs of maternal and neonatal medical care after beta-adrenergic drug treatment, given to arrest preterm labor, with expected costs associated with no gestational delay. The treatment arrested labor for at least three days in 61 per cent of patients; gestation was extended by 14.1 +/- 1.1 weeks (mean +/- S.E.M.) in infants with the earliest gestational age at treatment (20 to 25 weeks) and by 2.3 +/- 0.7 weeks in those with the latest gestational age (36 to 37 weeks). Costs were based on hospital charges and physicians' fees, including high-risk obstetric outpatient charges, obstetric prenatal and delivery inpatient charges, and pediatric inpatient charges. Treatment provided between 26 and 33 weeks of gestation was clearly cost effective, resulting in expected savings of $11,240 (1981 dollars) per birth. After 33 weeks there was no substantial difference in expected costs with or without treatment. Between 20 and 25 weeks of gestation, the expected costs per surviving infant were $39,000 lower with treatment; however, the number of mothers who were not treated at this early stage of gestation (three patients) was too small to permit statistical significance. When the improved survival of infants after prenatal treatment was taken into account, treatment before 25 weeks was also cost effective. Thus, the increased costs of prenatal medical care were offset by decreased costs of neonatal medical care when treatment was given before 34 weeks of gestation.