In a retrospective cohort study of 103 368 patients with type 2 diabetes mellitus, the incidence of diabetic macular edema (DME) was higher among users compared with nonusers of thiazolidinediones (odds ratio, 3.3 [95% CI, 2.2-5.0], and hazard ratio [HR], 2.3 [95% CI, 1.7-3.0], at 1 year and 10 years, respectively). This result was seen after adjustment for important factors that may influence the risk of DME, multiple imputation analysis to adjust for missing values, and propensity score analysis to exclude any selection bias. Combination therapy with insulin plus a thiazolidinedione was associated with a higher risk of DME after propensity score adjustment (HR, 3.0 [95% CI, 1.5-5.9]); meanwhile, aspirin use (HR, 0.6 [95% CI, 0.4-0.9]) and angiotensin-converting enzyme inhibitor use (HR, 0.4 [95% CI, 0.2-0.7]) were associated with a reduced risk of DME. Clinicians should be vigilant in the clinical screening for DME among those patients taking thiazolidinediones.