To ascertain the relationship between receipt of antidepressant agents and the risk of subsequent dementia in migraine patients. A population-based case-control analysis, using the Taiwan National Health Insurance Research Database. We identified 1774 patients with dementia and 1774 matched nondementia controls from migraine patients enrolled in the Taiwan National Health Insurance program between 2005 and 2011. The proportional distributions of exposure to three classes of antidepressant were compared between dementia and nondementia groups. Univariable and multivariable logistic regression analyses were used to estimate odds ratios (ORs) and 95% confidence intervals (CIs) for the risk of dementia based on antidepressant exposure. The proportions of subjects taking tricyclic antidepressants (TCAs), selective serotonin reuptake inhibitors (SSRIs), and new-generation antidepressants (NGAs) in dementia versus nondementia groups are 52.3 vs 51.2%, 25.5 vs 30.7%, and 18.8 vs 6.26%, respectively. The adjusted ORs of dementia were 1.02 (95% CI = 0.89, 1.17; P = 0.56) for TCAs, 0.58 (95% CI = 0.50, 0.69; P < 0.001) for SSRIs, and 4.23 (95% CI = 3.34, 5.37; P < 0.001) for NGAs. Treatment with SSRIs was associated with a decreased risk of dementia in migraine patients. TCAs showed no association with dementia risk, and NGAs showed increased risk. Given the possibility of confounding by indication, additional prospective trials and basic research are needed before drawing conclusions about the population-level risks for dementia onset conferred by antidepressant medications.