Histone demethylase that specifically demethylates trimethylated 'Lys-27' of histone H3, a mark associated with transcriptional repression, thereby playing a central role in the histone code. Involved in the transcriptional regulation of the heat shock response, unfolded protein response and possibly other stress response target genes. Required for gonad development and organization. Required for the robust transdifferentiation of the Y rectal epithelial cell to the PDA motor neuron during larval development. Acts cell-autonomously in Y-to-PDA transdifferentiation, which depends on the demethylase activity and on recognition of the H3 tail. Cooperates with set-2 and unc-3 to ensure robust Y-to-PDA transdifferentiation. Promotes mitochondrial stress-induced longevity. Involved in lifespan regulation