The transcription factor nuclear factor κB (NF-κB) rapidly reprograms gene expression in response to various stimuli, and its activity is regulated by several posttranslational modifications, including phosphorylation, methylation, and acetylation. The addition of O-linked β-N-acetylglucosamine (a process known as O-GlcNAcylation) is an abundant posttranslational modification that is enhanced in conditions such as hyperglycemia and cellular stress. We report that the NF-κB subunit c-Rel is modified and activated by O-GlcNAcylation. We identified serine 350 as the site of O-GlcNAcylation, which was required for the DNA binding and transactivation functions of c-Rel. Blocking the O-GlcNAcylation of this residue abrogated c-Rel-mediated expression of the cytokine-encoding genes IL2, IFNG, and CSF2 in response to T cell receptor (TCR) activation, whereas increasing the extent of O-GlcNAcylation of cellular proteins enhanced the expression of these genes. TCR- or tumor necrosis factor (TNF)-induced expression of other NF-κB target genes, such as NFKBIA (which encodes IκBα) and TNFAIP3 (which encodes A20), occurred independently of the O-GlcNAcylation of c-Rel. Our findings suggest a stimulus-specific role for hyperglycemia-induced O-GlcNAcylation of c-Rel in promoting T cell-mediated autoimmunity in conditions such as type 1 diabetes by enhancing the production of T helper cell cytokines.