To examine the risks of genital herpes and antiherpes treatment during pregnancy in relation to preterm delivery (PTD), we conducted a multicenter, member-based cohort study within 4 Kaiser Permanente regions: northern and southern California, Colorado, and Georgia. The study included 662,913 mother-newborn pairs from 1997 to 2010. Pregnant women were classified into 3 groups based on genital herpes diagnosis and treatment: genital herpes without treatment, genital herpes with antiherpes treatment, and no herpes diagnosis or treatment (unexposed controls). After controlling for potential confounders, we found that compared with being unexposed, having untreated genital herpes during first or second trimester was associated with more than double the risk of PTD (odds ratio (OR) = 2.23, 95% confidence interval (CI): 1.80, 2.76). The association was stronger for PTD due to premature rupture of membrane (OR = 3.57, 95% CI: 2.53, 5.06) and for early PTD (?35 weeks gestation) (OR = 2.87, 95% CI: 2.22, 3.71). In contrast, undergoing antiherpes treatment during pregnancy was associated with a lower risk of PTD compared with not being treated, and the PTD risk was similar to that observed in the unexposed controls (OR = 1.11, 95% CI: 0.89, 1.38). The present study revealed increased risk of PTD associated with genital herpes infection if left untreated and a potential benefit of antiherpes medications in mitigating the effect of genital herpes infection on the risk of PTD.