Together, our data identified that TRIM31 negatively regulated the activation of NLRP3 inflammasome in Hp-associated gastritis by affecting ROS and autophagy of gastric epithelial cells. This evidence concerns the gene TRIM31 and gastritis.