Krppel-like factor 4 (Klf4), a transcription factor, plays a key role in maintaining pluripotency of stem cells. Here we showed that Klf4 was highly expressed in thymocyte subsets and mature T cells, and was rapidly down-regulated in mature T cells after activation. In the absence of Klf4, we observed a modest reduction of T cell numbers in thymus (27%) associated with increased expression of Cdkn1b and reduced proliferation of thymocytes. Furthermore, we observed significant reduction of interleukin 17 (IL-17) expressing CD4+ T cells (TH17) after in vitro differentiation in the absence of Klf4 and demonstrated that Klf4 directly binds the promoter and positively regulates IL-17 expression. Furthermore, the reduced TH17 cells in the Klf4 deficient mice resulted in a significant reduction of the severity of experimental autoimmune encephalomyelitis (EAE). Together, these findings identify Klf4 as a critical regulator during T cell development and TH17 differentiation.