In mouse embryonic stem cells (ESCs), the pluripotency factor Nanog is heterogeneously downregulated via ERK signalling to facilitate differentiation (e.g. into primitive endoderm). However, the mechanism for Nanog silencing has been unclear. Now, Agnès Dubois, Pablo Navarro and colleagues investigate the histone modifications associated with Nanog repression. By comparing heterogenous and homogenous (e.g. ERK-inhibited) populations of NANOG-positive ESCs, the authors identify H3K9me3 as a mark associated with ERK-dependent Nanog silencing. Indeed, CRISPR/Cas9-mediated removal of the underlying region reduces the capacity of ESCs to enter a NANOG-negative state. Time-course studies reveal that H3K9me3 marks the appropriate timing for the irreversible commitment of cells during differentiation. ΔK9 clones, which lack H3K9me3 at Nanog, thus exhibit delayed differentiation and fail to engage the primitive endoderm programme efficiently, even under directed conditions. To investigate the mechanisms by which H3K9me3 is established, the researchers identify two candidates, DNMT3a and ZFP57, which bind the H3K9me3-enriched region at the Nanog locus. They show that ZFP57, which binds DNA methylated by DNMTs and has a known role in recruiting H3K9 methylases, mediates H3K9me3 at Nanog. Notably, the loss of ZFP57 or DNMTs phenocopies ΔK9 clones. Together, these data reveal a regulatory axis linking ERK signalling and the epigenetic silencing of Nanog via the transcription factor ZFP57.