Dermatomyositis (DM) is an autoimmune disorder characterized by proximal muscle weakness and distinct cutaneous features. Unfortunately, infection is a frequent and potentially life-threatening complication in patients with DM. Here, we present a case of pyomyositis in a patient with DM resulting from localized cellulitis. The patient also presented with subcutaneous calcification nodules and dermatomyositis-associated lipodermatosclerosis nodules. To our knowledge, there have been no reports of pyomyositis in patients with DM to date. Furthermore, we reviewed the infectious complications related to DM and polymyositis (PM). We found that idiopathic inflammatory myopathy (IIM) patients exhibit a considerable infection-related mortality rate, ranging from 4.3% to 7.2%. In IIM, infections were identified as the primary cause of mortality in a substantial proportion of cases, accounting for 22.0–83.3% of deaths. These findings have implications for the importance of identifying and managing infections in IIM patients and suggest the need for further research into infection-related complications in these patients.