On 27 May 1084, after an appeal from Pope Gregory VII, Norman duke Robert Guiscard entered Rome to defend Gregory from the forces of Holy Roman Emperor Henry IV and his anti-pope Clement III.
The roots of the conflict between Gregory and Henry lay in what was known as the Investiture Controversy, whether the secular ruler or the pope possessed the authority to appoint bishops within particular dioceses. Henry wished to appoint bishops within his empire and so placed a “pope” supportive to this view – Clement – in power at Saint Peter’s in Rome. Yet, as the conflict between Henry and Gregory grew, the issue of contention became more and more one concerned with the power of the papacy versus the power of the king.
At the time anti-pope Clement III was installed by Henry at Saint Peter’s, Gregory continued to resist Henry just a short distance away at Castel San Angelo. He asked for help from Robert Guiscard who responded by sending and army of 36,000 soldiers to enter Rome and rescue the pope. However, Guiscard’s armies also pillaged Rome for three days and partially burned the city – leading to the destruction many ancient buildings including the original basilica of San Clemente and the church of Santa Maria in Cosmodin.
Gregory died a year later in exile but his views on the secular primacy of the pope would be taken up by his successors while the support of Henry IV would decline.