The origins of the Caetani castle, which dominates the medieval village of Sermoneta, date back to the 13th century when it was in the hands of the Annibaldi family. By then it was already characterized by two fortified keeps, the Maschio, a 42-metre-high tower, and an adjacent smaller, known as the Maschietto.
In 1297, Pietro Caetani, used the suasion of his uncle Pope Boniface VIII to acquire a number of properties from the Annibaldi family. These included Sermoneta and Bassiano. In the 15th century, the Caetani significantly expanded the castle at Sermoneta. The collegiate church of San Pietro, where the remains of the Caetani family were kept, was re-sited within the Piazza D’Armi. The Camere Pinte, frescoed rooms with mythological and allegorical scenes, date back to the 1470.
In 1499 Pope Borgia Alexander VI, excommunicated the Caetani and took possession of their property, depriving them of privileges and rights. Under the Borgia, the castle became a military fortress: the city walls were reinforced, the citadel was constructed, as was the walkway running the length of the battlements. The upper level of the Maschio was destroyed and with it the Church of San Pietro in Corte, which was razed to the ground with no respect for the remains of the Caetani buried there since 1400.