For this reason, even if the presence of factions inside the town could not be prevented, Anagni remained faithful to the Roman Church, becoming one of the favourite residences of the popes, in the 12th and 13th centuries.
V 9. stoletju je bila zgrajena prva katedrala na ruševinah templja posvečenega boginji Ceres.