Plenty of odd things have been put on trial—animals, statues, a washerwoman's vat—but there's only one occasion in history that a dead body has gone before a papal court. The Cadaver Synod (Synodus Horrenda in Latin) has been called "one of the grisliest events in papal history," which, given the intrigues of the medieval church, is saying something.

The cadaver in question belonged to Pope Formosus, who suffered a series of dramatic reversals in both life and death. Born probably in Rome around 816, he was appointed bishop of the Italian city of Porto in 864 by Pope St. Nicholas I, who then sent him on a missionary expedition to Bulgaria. That went so well the King of Bulgaria wanted Formosus to lead an autonomous church there, but the request was denied by the then-current pope, John VIII, who thought Formosus was getting a little too big for his britches.

Nevertheless, Formosus remained a respected figure who played important roles in the church in France and Italy for decades—at least until he irritated John VIII enough to get excommunicated in 872. A later pope restored Formosus, and in 891 Formosus became pope himself. His five-year reign was relatively lengthy by the standards of the day, and it ended only when he died of a stroke in 896.

But in death, Formosus became famous for an even more dramatic reversal than any he had suffered in life. Yet another pope whom he'd annoyed, Stephen VI, had his nine-months-rotten corpse exhumed, dressed in papal vestments, perched on a throne, and forced to answer for his "crimes." Unsurprisingly, his answers weren't very convincing.

Pope Formosus in a 1588 portraitCavallieri, Wikimedia Commons // Public Domain

A complete understanding of the events that precipitated the Cadaver Synod involves following the politics of the papacy, Holy Roman Emperors, and Western European aristocrats for several decades. But as Laura Jeffries distills it in Great Events in Religion, "Essentially, Formosus encountered such a fearsome posthumous reprisal because he chose the losing side in one of many struggles for political control after fall of the Carolingian dynasty in 9th century." In other words, the cadaverous pope's crimes weren't so much spiritual as political, and emerged in the chaotic period that followed the death of Charlemagne—the first Holy Roman Emperor—in 814.

There were two main issues: First, Stephen VI belonged to the house of Spoleto, a powerful Roman family Formosus had angered in 894 after asking a Frankish king, Arnulf, to invade Italy. At the time, Guido of Spoleto (also known as Guy III) was the Holy Roman Emperor, but he was seen as an aggressive ruler who had little respect for the rights and privileges of the Holy See. The invasion was a failure, but it still smarted, and the Spoleto family never forgot the challenge to their precarious authority.

The second factor, according to Elizabeth Harper at Atlas Obscura, may have actually been more important. Although he was very much dead, poor, decomposing Formosus posed a challenge to Stephen VI's legitimacy. Ironically, that was because Stephen VI could be accused of some of the same crimes Formosus was charged with. These "crimes" amounted to being a bishop in two jurisdictions at once—both in Porto and the diocese of Rome, the latter a role that comes with the papacy—as well as openly aspiring to the papacy. By Stephen VI's logic, the double bishopric, a violation of canon law, invalidated Formosus's whole papacy, including all his acts and appointments.

That invalidation was handy, since as Harper explains, "Formosus had made Stephen bishop, and Stephen had become bishop of Rome … while he still held that post. But if Formosus could be found guilty of that same crime (being a simultaneous bishop of two places), his actions would be null and Stephen wouldn't have been a bishop when he was elected pope. Stephen also might have been completely insane.”

In any event, Formosus's body was exhumed from its burial place at Saint Peter's Basilica, dressed in papal robes, and seated for trial at the Basilica of St. John Lateran. There's no transcript of the trial, but Jeffries notes that by several accounts, "Stephen screamed and raved throughout the proceedings while a young deacon was forced to stand by and answer questions on behalf of the corpse." Partway through, an earthquake shook the building, presumably adding to the ominous vibe—although no one seems to have taken it as a sign to stop.

The assembled ecclesiastical authorities (whose gatherings are called a synod) found Formosus guilty on all counts. Since they couldn't kill him, he was stripped of his papal vestments and had the three fingers of his right hand that he'd used for consecration during his life severed. His body was buried in a common grave, but exhumed once again not long afterwards and thrown in the Tiber River.

However, Stephen IV suffered his own reversal, too. The outraged populace imprisoned him after the trial, and soon after that, some of Formosus's supporters strangled him to death in his cell.

Formosus's body didn't stay in the river long: Under the next few popes, it was pulled from the river, redressed in sacred robes, and reburied at St. Peter's Basilica. (It took a few popes to accomplish because they had the life expectancy of mayflies at that point.)

The period that followed was one of the most corrupt and tumultuous in the church's history, with rival factions jockeying for power and annulling one another's work if not outright killing each other. But there was one bright spot: In 898, Pope John IX wisely forbade the trial of any dead pope—or any dead person at all—in the future. Thus the Cadaver Synod would remain a unique, and uniquely terrible, event in history.