Background Limited data exist regarding the disease course of coronavirus disease 2019 (COVID-19) and its relationship with immunosuppressants among patients with immune-mediated inflammatory diseases (IMIDs). Therefore, this study aims to investigate the association between COVID-19, frequent rheumatological, dermatological, gastrointestinal, and neurological IMIDs and immunosuppressants. Methods We conducted a Danish population-based cohort study including all residents living within Capital Region of Denmark and Region Zealand from January 28th, 2020 until September 15th, 2020 with the only eligibility criterion being a test for SARS-CoV-2 via reverse transcription–polymerase chain-reaction. Main outcomes included development of COVID-19, COVID-19-related hospitalization and mortality. Results COVID-19 was less common among patients with IMIDs than the background population (n = 328/20,513 (1.60%) and n = 10,792/583,788(1.85%), p < 0.01, respectively). However, those with IMIDs had a significantly higher risk of COVID-19-related hospitalization (31.1% and 18.6%, p < 0.01, respectively) and mortality (9.8% and 4.3%, p < 0.01, respectively), which were associated with patients older than 65 years, and presence of comorbidities. Furthermore, systemic steroids were independently associated with a severe course of COVID-19 (Odds ratio (OR) = 3.56 (95%CI 1.83–7.10), p < 0.01), while biologic therapies were associated with a reduced risk hereof (OR = 0.47 (95%CI 0.22–0.95), p = 0.04). Patients suspending immunosuppressants due to COVID-19 had an increased risk of subsequent hospitalization (OR = 3.59 (95%CI 1.31–10.78), p = 0.02). Conclusion This study found a lower occurrence, but a more severe disease course, of COVID-19 among patients with IMIDs, which was associated with the use of systemic steroids for IMIDs and suspension of other immunosuppressants. This study emphasizes the importance of weighing risks before suspending immunosuppressants during COVID-19.