Quantum field theory in curved spacetime is used to show that gravitational redshift induces a unitary transformation on the quantum state of propagating photons. It is found that the transformation is a mode-mixing operation, and a protocol that exploits gravity to induce a Hong–Ou–Mandel-like interference effect on the state of two photons is devised. It is discussed how the results of this work can provide a demonstration of quantum field theory in curved spacetime.