The daily diet plays a role in systematic inflammation and may be one of the causes of preterm birth. We aimed to examine the effect of a daily proinflammatory diet before pregnancy on gestational age and birthweight using a large birth cohort in Japan. We used data of singleton pregnancies in the Japan Environment and Children's Study involving live birth from 2011 to 2014 to calculate the dietary inflammatory index. We used individual meals with 30 food parameters from a semiquantitative food frequency questionnaire, which assessed diet intake before pregnancy. Participants were categorized according to the quartile of dietary inflammatory index. A multiple logistic regression model was used to estimate the risk of a proinflammatory diet on preterm birth (PTB) before 37 or 34 weeks and low birthweight (LBW) less than 2,500 or 1,500 g, accounting for maternal age, body mass index before pregnancy, smoking status, education, and household income. After applying our inclusion criteria, 89,329 participants were eligible for the present study. Multiple regression analysis showed that the proinflammatory diet had an increased risk of PTB < 34 weeks (adjusted odds ratio: 1.29, 95% confidence interval [1.07, 1.55]) and <2,500‐g LBW (adjusted odds ratio: 1.08, 95% confidence interval [1.01, 1.16]) compared with the control. In conclusion, a proinflammatory diet before pregnancy was a risk factor for PTB < 34 weeks and LBW < 2,500 g. Therefore, proinflammatory diet needs to be controlled to improve perinatal prognosis.