Despite the recognized significance of reversible protein lipidation (S-acylation) for T cell receptor signal transduction, the enzymatic control of this post-translational modification in T cells remains poorly understood. Here, we demonstrate that DHHC21 (also known as ZDHHC21), a member of the DHHC family of mammalian protein acyltransferases, mediates T cell receptor-induced S-acylation of proximal T cell signaling proteins. Using Zdhhc21dep mice, which express a functionally deficient version of DHHC21, we show that DHHC21 is a Ca2+/calmodulin-dependent enzyme critical for activation of naïve CD4+ T cells in response to T cell receptor stimulation. We find that disruption of the Ca2+/calmodulin-binding domain of DHHC21 does not affect thymic T cell development but prevents differentiation of peripheral CD4+ T cells into Th1, Th2 and Th17 effector T helper lineages. Our findings identify DHHC21 as an essential component of the T cell receptor signaling machinery and define a new role for protein acyltransferases in regulation of T cell-mediated immunity.