Importance: Systemic and inhaled corticosteroids negatively affect bone remodeling and cause osteoporosis and bone fracture when given continuously or in high doses. However, risk of osteoporosis and major osteoporotic fracture (MOF) after application of topical corticosteroids (TCSs) is largely unexplored. Objective: To examine the association between cumulative exposure to potent and very potent TCSs and risk of osteoporosis and MOF. Design, Setting, and Participants: This nationwide retrospective cohort study included 723251 Danish adults treated with potent or very potent TCSs from January 1, 2003, to December 31, 2017. Data were obtained from Danish nationwide registries. Filled prescription data were converted in equipotent doses to mometasone furoate (1 mg/g). Data were analyzed from June 1 to August 31, 2019. Exposures: Patients were considered exposed when they had filled prescriptions of cumulative amounts corresponding to the equivalent of at least 500 g of mometasone, using filled prescriptions of 200 to 499 g as the reference group. Main Outcomes and Measures: The co-primary outcomes were a diagnosis of osteoporosis or MOF. Hazard ratios (HRs) adjusted for age, sex, socioeconomic status, medication use, and comorbidity were calculated with 95% CIs using Cox proportional hazards regression models. Results: A total of 723251 adults treated with the equivalent of at least 200 g of mometasone were included in the analysis (52.8% women; mean [SD] age, 52.8 [19.2] years). Dose-response associations were found between increased use of potent or very potent TCSs and the risk of osteoporosis and MOF. For example, HRs of MOF were 1.01 (95% CI, 0.99-1.03) for exposure to 500 to 999 g, 1.05 (95% CI, 1.02-1.08) for exposure to 1000 to 1999 g, 1.10 (95% CI, 1.07-1.13) for exposure to 2000 to 9999 g, and 1.27 (95% CI, 1.19-1.35) for exposure to at least 10 000 g. A 3% relative risk increase of osteoporosis and MOF was observed per doubling of the cumulative TCS dose (HR, 1.03 [95% CI, 1.02-1.04] for both). The overall population-attributable risk was 4.3% (95% CI, 2.7%-5.8%) for osteoporosis and 2.7% (95% CI, 1.7%-3.8%) for MOF. The lowest exposure needed for 1 additional patient to be harmed (454 person-years) was observed for MOF with exposure of at least 10000 g. Conclusions and Relevance: These findings demonstrate that use of high cumulative amounts of potent or very potent TCSs was associated with an increased risk of osteoporosis and MOF.