Background: The aim of this study was to investigate the association between temporomandibular disorder (TMD) and migraine through a longitudinal follow-up study using population data from a national health screening cohort. Methods: This cohort study used data from the Korean National Health Insurance Service-Health Screening Cohort from 2002 to 2015. Of the 514,866 participants, 3884 TMD patients were matched at a 1:4 ratio with 15,536 control participants. Crude models and models adjusted for obesity, smoking, alcohol consumption, systolic blood pressure, diastolic blood pressure, fasting blood glucose, total cholesterol, and Charlson Comorbidity Index (CCI) scores were calculated. Chi-squared test, Kaplan–Meier analysis, and two-tailed log-rank test were used for statistical analysis. Stratified Cox proportional hazard models were used to assess hazard ratios (HR) and 95% confidence intervals (CIs) for migraine in both control groups. Results: The adjusted HR for migraine was 2.10 (95% CI: 1.81–2.44) in the TMD group compared to the control group, which was consistent in subgroup analyses according to age, sex, and Kaplan–Meier analysis. Conclusions: This study demonstrated that TMD patients have a higher risk of migraine. These results suggest that dentists can decrease the risk of migraine in TMD patients by managing TMD properly.