Aims/hypothesis Type 1 diabetes mellitus is a major public health problem of increasing global concern, with potential neurological complications. A possible association exists between type 1 diabetes and subsequent epilepsy. This study evaluated the relationship between type 1 diabetes and epilepsy in Taiwan. Methods Claims data from the Taiwan National Health Insurance Research Database were used to conduct retrospective cohort analyses. The study cohort contained 2568 patients with type 1 diabetes, each of whom was frequency-matched by sex, urbanisation of residence area and index year with ten patients without type 1 diabetes. Cox proportional hazard regression analysis was conducted to estimate the effects of type 1 diabetes on epilepsy risk. Results In patients with type 1 diabetes, the risk of developing epilepsy was significantly higher than that in patients without type 1 diabetes (p < 0.0001 for logrank test). After adjustment for potential confounders, the type 1 diabetes cohort was 2.84 times as likely to develop epilepsy than the control cohort was (HR 2.84 [95% CI 2.11, 3.83
]).Conclusions/interpretation Patients with type 1 diabetes are at an increased risk of developing epilepsy. Metabolic abnormalities of type 1 diabetes, such as hyperglycaemia and hypoglycaemia, may have a damaging effect on the central nervous system and be associated with significant long-term neurological sequelae. The causative factors between type 1 diabetes and the increased risk of epilepsy require further investigation.