Gli3 is a Hedgehog (Hh)-responsive transcription factor that can function as a transcriptional repressor or activator. We show that Gli3 activity in mouse thymic epithelial cells (TECs) promotes positive selection and differentiation from CD4+ CD8+ to CD4+ CD8− single-positive (SP4) cells in the fetal thymus and that Gli3 represses Shh. Constitutive deletion of Gli3, and conditional deletion of Gli3 from TECs, reduced differentiation to SP4, whereas conditional deletion of Gli3 from thymocytes did not. Conditional deletion of Shh from TECs increased differentiation to SP4, and expression of Shh was upregulated in the Gli3-deficient thymus. Use of a transgenic Hh reporter showed that the Hh pathway was active in thymocytes, and increased in the Gli3-deficient fetal thymus. Neutralisation of endogenous Hh proteins in the Gli3−/− thymus restored SP4 differentiation, indicating that Gli3 in TECs promotes SP4 differentiation by repression of Shh. Transcriptome analysis showed that Hh-mediated transcription was increased whereas TCR-mediated transcription was decreased in Gli3−/− thymocytes compared with wild type.