While the effects of dietary patterns on cardiovascular risk and diabetes have been well studied, the evidence is scarce as to which diet has the greatest anti-inflammatory potential and how dietary patterns are associated with periodontitis. In the Hamburg City Health Study (HCHS), we developed an anti-inflammatory dietary score using a data-driven approach based on the relationship of relevant selected food groups with inflammatory biomarkers (hsCRP and IL-6). The aim of this cross-sectional study was to evaluate the association between the anti-inflammatory dietary score and the incidence of periodontitis in Hamburg, Germany. A total of n = 5642 participants fit the required inclusion criteria and were selected for analysis. Periodontal disease was assessed using probing depth, gingival recession, and bleeding on probing. Dietary intake was measured using a food frequency questionnaire (FFQ). A self-developed anti-inflammatory dietary score served as the key explanatory variable. Higher scores reflected lower inflammatory processes (measured through the biomarkers hsCRP and IL-6). Several covariates were included in the regression analysis. Regressions revealed that a higher anti-inflammatory dietary score was significantly associated with lower odds to be affected by periodontal disease in an unadjusted model (OR 0.86, 95% CI 0.82-0.89, p < 0.001) and in an adjusted model (age, sex, smoking, diabetes, hypertension, and physical activity) (OR 0.93, 95% CI 0.89-0.98, p = 0.003). Our study demonstrated a significant inverse association between an anti-inflammatory dietary score and periodontitis. Individuals with higher intake of proinflammatory nutrition should be specifically addressed to avoid periodontitis.