Age of Apostasy
The Age of Apostasy is one of the major time periods of the Imperium of Man. It began around M36, when Goge Vandire, Master of the Administratum, had the Ecclesiarch assassinated and took control of the church himself. 40K being 40K, power went to his head and he began the so-called "Reign of Blood", in which he purged the Imperium of any dissenters with the backing of armies of millions of frenzied Imperial Cultists, led by his Preachers. Vandire proved difficult to unseat, as he was protected by an order of warrior women known as the Brides of the Emperor.
Eventually, the people of the Imperium grew tired of Vandire's rule, and when a young man named Sebastian Thor started warring against the mad High Lord, he was soon joined by a massive army. Vandire sent a fleet to deal with Thor's army, but when it was lot in the Warp, people took that as a sign that the Emperor favored Thor, and he became even more popular.
When Thor finally got to Terra, he joined forces with the Space Marines and Adeptus Mechanicus (who had never been friendly with the Ecclesiarchy to begin with), and managed to dislodge Vandire, forcing him to retreat to the heavily-fortified Ecclesiarchical sanctum of the Imperial Palace. The Adeptus Custodes managed to infiltrate the compound (as they defended the Emperor, who was at the center of the Palace) and brought the leader of the Brides of the Emperor to a face-to-face meeting with the big man himself. What exactly was said is unknown, but she ended up executing Vandire herself.
With Vandire dead, Thor became the new Ecclesiarch, and he instituted some reforms. First, he toned down the grandeur, insisting that the Church serve the Imperium as much as the other way around. Second, he decreed that the Ecclesiarchy should have no "men under arms". Finally, he reformed the Brides of the Emperor into the Adepta Sororitas (as they were women under arms) to serve as the Church's armed force.
As proof that no good deed goes unpunished, his head got taken by Trazyn the Infinite.