To estimate the incidence of ectopic pregnancy (EP) associated with prescription contraceptive use. We performed a retrospective cohort study of women aged 15 to 44 years at Kaiser Permanente Northern and Southern California during 2010 to 2019. We identified EPs and prescription contraceptive use from diagnosis, procedural, and medication codes, and natural language processing of clinical notes from electronic health records. Contraceptive use categories included combined hormonal contraceptives, intrauterine devices, depot-medroxyprogesterone acetate (DMPA), progestin-only pills (POPs), implants, no method after recent discontinuation of a prescription contraceptive in the last 12 months, and no method after discontinuation of a prescription contraceptive more than 12 months ago or no use of prescription contraceptives during the study period. Contraceptive use was updated as women started, stopped, or changed methods. An EP was attributed to a contraceptive method if it occurred 14 days after starting and up to 42 days after stopping a method. Age-adjusted EP incidence and 95% confidence intervals (CI) were estimated per 10,000 woman-years overall and by contraceptive category. There were 11,436 EPs among 3,204,118 women with 11,909,842 woman-years of follow-up for an overall EP incidence of 9.5 per 10,000 woman-years (95%CI 9.3-9.6). The majority of EPs (9662; 84.5%) occurred during no prescription contraceptive use. EP incidence was lowest during DMPA (1.8 per 10,000 woman-years [95%CI 1.2-2.5]) or implant (2.0 per 10,000 woman-years [95%CI 1.2-3.3]) use, and higher during POP use at 15.2 (95%CI 12.2-19.6); however, incidence was highest after recent discontinuation of a prescription contraceptive (20.6 per 10,000 woman-years [95%CI 19.7-21.4]). EP incidence is lower with prescription contraceptive use than with nonuse. All prescription contraceptives, including POPs are protective of EP.