Therefore, our study identifies a previously uncharacterized mechanism for the regulation of SMAD2 activation and Th17 cell differentiation, which suggests that targeting the DHHC7- and APT2-mediated S-palmitoylation–depalmitoylation cycle of SMAD2 could serve as a potential therapeutic approach to treat autoimmune diseases. Here, ZDHHC7 is linked to autoimmune disease.