Adaptation to a changing environment is an essential feature of physiological regulation. The day-night rhythm is translated into hormonal oscillations governing the metabolism of all living organisms. In mammals the pineal gland is responsible for the synthesis of the hormone melatonin in response to signals originating from the endogenous clock located in the hypothalamic suprachiasmatic nucleus (SCN). The molecular mechanisms involved in rhythmic synthesis of melatonin involve the cAMP response element modulator (crem) gene, which encodes transcription factors responsive to activation of the cAMP signalling pathway. The CREM product, inducible cAMP early repressor (ICER), is rhythmically expressed and participates in a transcriptional autoregulatory loop that also controls the amplitude of oscillations of 5-HT N-acetyl transferase, the rate-limiting enzyme of melatonin synthesis. Thus, a transcription factor modulates the oscillatory levels of a hormone.