Both epilepsy and enzyme-inducing antiseizure medications (eiASMs) having varying reports of an association with increased risks for osteoporosis. To quantify and model the independent hazards for osteoporosis associated with incident epilepsy and eiASMS and non-eiASMs. This open cohort study covered the years 1998 to 2019, with a median (IQR) follow-up of 5 (1.7-11.1) years. Data were collected for 6275 patients enrolled in the Clinical Practice Research Datalink and from hospital electronic health records. No patients who met inclusion criteria (Clinical Practice Research Datalink-acceptable data, aged 18 years or older, follow-up after the Hospital Episode Statistics patient care linkage date of 1998, and free of osteoporosis at baseline) were excluded or declined. Incident adult-onset epilepsy using a 5-year washout and receipt of 4 consecutive ASMs. The outcome was incident osteoporosis as determined through Cox proportional hazards or accelerated failure time models where appropriate. Incident epilepsy was treated as a time-varying covariate. Analyses controlled for age, sex, socioeconomic status, cancer, 1 or more years of corticosteroid use, body mass index, bariatric surgery, eating disorders, hyperthyroidism, inflammatory bowel disease, rheumatoid arthritis, smoking status, falls, fragility fractures, and osteoporosis screening tests. Subsequent analyses (1) excluded body mass index, which was missing in 30% of patients; (2) applied propensity score matching for receipt of an eiASM; (3) restricted analyses to only those with incident onset epilepsy; and (4) restricted analyses to patients who developed epilepsy at age 65 years or older. Analyses were performed between July 1 and October 31, 2022, and in February 2023 for revisions. Of 8 095 441 adults identified, 6275 had incident adult-onset epilepsy (3220 female [51%] and 3055 male [49%]; incidence rate, 62 per 100 000 person-years) with a median (IQR) age of 56 (38-73) years. When controlling for osteoporosis risk factors, incident epilepsy was independently associated with a 41% faster time to incident osteoporosis (time ratio [TR], 0.59; 95% CI, 0.52-0.67; P < .001). Both eiASMs (TR, 0.91; 95% CI, 0.87-0.95; P < .001) and non-eiASMs (TR, 0.77; 95% CI, 0.76-0.78; P < .001) were also associated with significant increased risks independent of epilepsy, accounting for 9% and 23% faster times to development of osteoporosis, respectively. The independent associations among epilepsy, eiASMs, and non-eiASMs remained consistent in propensity score-matched analyses, cohorts restricted to adult-onset epilepsy, and cohorts restricted to late-onset epilepsy. These findings suggest that epilepsy is independently associated with a clinically meaningful increase in the risk for osteoporosis, as are both eiASMs and non-eiASMs. Routine screening and prophylaxis should be considered in all people with epilepsy.