Background: Osteoporosis and bone fractures affect health and quality of life. Since bone disease is multifactorial, identifying risk factors is key in prevention. There are multiple reports on how viral hepatitis, especially chronic hepatitis B (CHB) and chronic hepatitis C (CHC), are affecting bone disease, but results vary. Here, we analyzed the potential association between CHB/CHC and osteoporosis or bone fractures in a large outpatient cohort in Germany. Methods: We included 3136 outpatients with CHB and 15,608 matched non-hepatitis individuals as well as 2867 outpatients with CHC and 14,335 matched non-hepatitis individuals from the Disease Analyzer Database between 2005 and 2022. The main outcome was the 5-year cumulative incidence of osteoporosis and bone fractures as a function of either CHB or CHC. Results: Within 5 years of the index date, 2.9% vs. 1.6% of patients with and without CHB were diagnosed with osteoporosis (p = 0.001) and 1.0% vs. 0.4% were diagnosed with bone fractures (p < 0.001). Moreover, 3.3% of CHC patients and 2.2% of individuals without hepatitis C were diagnosed with osteoporosis (p = 0.002). In Cox regression analyses, CHB was significantly associated with an increased risk for osteoporosis (HR: 1.76) and fractures (HR:2.43) and CHC with osteoporosis (HR: 1.54). For both CHB and CHC, the association with osteoporosis was restricted to the female subgroup. Conclusions: CHB and CHC are associated with osteoporosis in women. CHB in male patients is associated with a higher risk of fractures. More research is needed to understand the underlying pathophysiological mechanisms.