The liturgical poem that says, “On Rosh Hashanah it is written, and on Yom Kippur it is sealed,” is Unetanneh Tokef.
Unetanneh Tokef is a piyyut, or Jewish liturgical poem, centered on divine judgment during the High Holy Days. Its famous passage describes a heavenly judgment in which each person’s fate for the coming year is written on Rosh Hashanah and sealed on Yom Kippur. The poem then declares that repentance, prayer, and charity can avert or lessen a severe decree.
In the Ashkenazi rite, it is generally recited during the repetition of the Mussaf Amidah, immediately before the Kedushah, often with the Torah ark open and the congregation standing. It is used on Rosh Hashanah and Yom Kippur in many traditions, though some Sephardic communities omit it or use it differently. The poem’s dramatic theme also inspired Leonard Cohen’s 1974 song “Who by Fire,” whose title echoes its list of possible fates.