Objective: to estimate the prevalence of severity of hospitalized cases of COVID-19 and its association with diabetes mellitus. Methods: a cross-sectional study, which used secondary data from the Influenza Epidemiological Surveillance Information System, totaling 405,294 confirmed cases. To verify the association of diabetes and severity in hospitalized patients with COVID-19, Poisson regression models with robust variance estimator were used. Initially, the association of disease with outcome was verified; next, several adjustments for potential confounders were performed. Results: the prevalence of diabetes in the 405,294 hospitalized and positive cases was 25.7% (Confidence Interval: 25.5% - 25.8%). After adjustments, diabetes was found to increase the severity of COVID-19 by 19% (Confidence Interval: 1.17 - 2.21). Conclusion: a significant association of diabetes mellitus with severe cases of COVID-19 infection has been identified. Contributions to practice: the evidence generated by the study guides the risk stratification of patients and directs clinical management.