Natural environments require organisms to possess robust mechanisms allowing responses to seasonal trends. In Arabidopsis halleri, the flowering regulator AhgFLC shows upregulation and downregulation phases along with long-term past temperature, but the underlying machinery remains elusive. Here, we investigate the seasonal dynamics of histone modifications, H3K27me3 and H3K4me3, at AhgFLC in a natural population. Our advanced modelling and transplant experiments reveal that H3K27me3-mediated chromatin regulation at AhgFLC provides two essential properties. One is the ability to respond to the long-term temperature trends via bidirectional interactions between H3K27me3 and H3K4me3; the other is the ratchet-like character of the AhgFLC system, i.e. reversible in the entire perennial life cycle but irreversible during the upregulation phase. Furthermore, we show that the long-term temperature trends are locally indexed at AhgFLC in the form of histone modifications. Our study provides a more comprehensive understanding of H3K27me3 function at AhgFLC in a complex natural environment.