Diabetes mellitus has been shown to impair respiratory function. The diaphragm is an important skeletal muscle involved in respiration. Hydrogen sulfide (H2S) is one of the three endogenous gas messengers in mammals, which exhibits anti-fibrotic activity in some types of diabetes-related complications. However, whether and how H2S exerts its anti-fibrotic activity on the diabetic diaphragmatic muscle remains unclear. In this study, we explored the anti-fibrotic activity of exogenous H2S on the diaphragm using a streptozotocin (STZ)-induced diabetic rat model. The results showed that diaphragmatic biomechanical parameters were decreased, whereas the levels of inflammatory cytokines, collagen, and nucleotide-binding oligomerization domain-like receptor protein (NLRP) 3 inflammasome-related protein expression were increased in diabetic diaphragms. This implies that diabetes causes fibrosis of the diaphragm muscle through activation of NLRP3 inflammasome. After supplementation with exogenous H2S, the diaphragmatic biomechanical and pathological alterations were ameliorated and activation of NLRP3 inflammasome was inhibited, followed by a decline in diaphragm muscle inflammation and fibrosis. These results demonstrate for the first time that exogenous H2S effectively attenuates STZ-induced diabetic diaphragm muscle fibrosis, and that the underlying mechanism may be associated with suppression of the NLRP3 inflammasome-mediated inflammatory reaction. Impact statement Diabetes mellitus is a group of chronic metabolic disorders, which causes serious damage to a variety of organs, such as the retina, heart, and skeletal muscle. The diaphragm is an important skeletal muscle involved in respiration in mammals. Fibrosis of the diaphragm muscle affects its contractility, which in turn impairs respiratory function. Accumulating evidence suggests that exogenous hydrogen sulfide (H2S) exhibits anti-fibrotic activity in diabetes mellitus, but whether and how H2S exerts this anti-fibrotic effect in the diabetic diaphragm remains unclear. The current work for the first time reveals that exogenous H2S attenuates hyperglycemia-induced fibrosis of the diaphragm muscle and strengthens diaphragmatic biomechanical properties in diabetes mellitus, and the mechanism may involve the alleviation of collagen deposition by suppression of the nucleotide-binding oligomerization domain-like receptor protein (NLRP) 3 inflammasome-mediated inflammatory reaction. Therefore, H2S supplementation could be used as an efficient targeted therapy against the NLRP3 inflammasome in the diabetic diaphragm.