Periodontitis is a multifactorial inflammatory disease that can cause tooth loss and contribute to systemic inflammation. It is suggested that periodontitis may be associated with the development of glaucoma. Based on data from Taiwan’s National Health Insurance Research Database, a retrospective cohort study was conducted to investigate the risk of developing glaucoma in patients with periodontitis. The periodontitis cohort consisted of newly diagnosed adult patients (n = 194,090, minimum age = 20 years) between 2000 and 2012. The comparison group included age-, gender-, and diagnosis date-matched people without periodontitis (n = 194,090, minimum age = 20 years). Incident glaucoma was monitored until the end of 2013. Hazard ratios (HRs) with confidence intervals (CIs) were established based on the Cox proportional hazard models. The risk of developing glaucoma was higher in patients with periodontitis than those without periodontitis (31.2 vs. 23.3 patients per 10,000 person-years, with an adjusted HR of 1.26 [95% CI 1.21–1.32]). A high risk was evident even after stratifying by age (adjusted HRs = 1.34 [1.26–1.44] for ages 20–49, 1.24 [1.13–1.36] for ages ≥ 65, and 1.20 [1.12–1.29] for ages 50–64 years), sex (adjusted HRs = 1.33 [1.24–1.41] and 1.21 [1.14–1.28] for men and women, respectively), presence of comorbidity (adjusted HRs = 1.38 [1.29–1.47] and 1.18 [1.12–1.25] for without and with comorbidity, respectively), and corticosteroid use (adjusted HRs = 1.27 [1.21–1.33] and 1.21 [1.08–1.35] for without and with corticosteroid use, respectively). Specifically, patients with periodontitis exhibited a significantly high risk of primary open-angle glaucoma (adjusted HR = 1.31 [1.21–1.32]) but not for primary closed-angle glaucoma (adjusted HR = 1.05 [0.94–1.17]). People with periodontitis are at a greater risk of glaucoma than individuals without periodontitis. Ocular health should be emphasized for such patients, and the underlying mechanisms need further investigation.