The COVID-19 pandemic introduced stresses on hospitals due to the surge in demand for care and to staffing shortages. The implications of these stresses for patient safety are not well understood. To assess whether hospital COVID-19 burden was associated with the rate of in-hospital adverse effects (AEs). This cohort study used data from the Agency for Healthcare Research and Quality's Quality and Safety Review System, a surveillance system that tracks the frequency of AEs among selected hospital admissions across the US. The study sample included randomly selected Medicare patient admissions to acute care hospitals in the US between September 1, 2020, and June 30, 2022. The main outcome was the association between frequency of AEs and hospital-specific weekly COVID-19 burden. Observed and risk-adjusted rates of AEs per 1000 admissions were stratified by the weekly hospital-specific COVID-19 burden (daily mean number of COVID-19 inpatients per 100 hospital beds each week), presented as less than the 25th percentile (lowest burden), 25th to 75th percentile (intermediate burden), and greater than the 75th percentile (highest burden). Risk adjustment variables included patient and hospital characteristics. The study included 40 737 Medicare hospital admissions (4114 patients [10.1%] with COVID-19 and 36 623 [89.9%] without); mean (SD) patient age was 73.8 (12.1) years, 53.8% were female, and the median number of Elixhauser comorbidities was 4 (IQR, 2-5). There were 59.1 (95% CI, 54.5-64.0) AEs per 1000 admissions during weeks with the lowest, 77.0 (95% CI, 73.3-80.9) AEs per 1000 admissions during weeks with intermediate, and 97.4 (95% CI, 91.6-103.7) AEs per 1000 admissions during weeks with the highest COVID-19 burden. Among patients without COVID-19, there were 55.7 (95% CI, 51.1-60.8) AEs per 1000 admissions during weeks with the lowest, 74.0 (95% CI, 70.2-78.1) AEs per 1000 admissions during weeks with intermediate, and 79.3 (95% CI, 73.7-85.3) AEs per 1000 admissions during weeks with the highest COVID-19 burden. A similar pattern was seen among patients with COVID-19. After risk adjustment, the relative risk (RR) for AEs among patients admitted during weeks with high compared with low COVID-19 burden for all patients was 1.23 (95% CI, 1.09-1.39; P < .001), with similar results seen in the cohorts with (RR, 1.33; 95% CI, 1.03-1.71; P = .03) and without (RR, 1.23; 95% CI, 1.08-1.39; P = .002) COVID-19 individually. In this cohort study of hospital admissions among Medicare patients during the COVID-19 pandemic, greater hospital COVID-19 burden was associated with an increased risk of in-hospital AEs among both patients with and without COVID-19. These results illustrate the need for greater hospital resilience and surge capacity to prevent declines in patient safety during surges in demand.