The Catholic church was the supreme power during most of the medieval period. Some of the ways the church exercised its power includes the flow of wealth, the use of sacraments to control people and their lives, the use of Church councils, the propaganda value of the religious beggars (friars), and finally, the horrible cruelty of the Inquisition and the fear it generated.
The Pope was alone at the top. Under the Pope were a few cardinals who were in charge of all the churches in large cities or territories. Bishops were under the cardinals. There were a lot of bishops. Each ran a large church or monastery (a place to train new priests) At the bottom rung were the local priests and monks who did all the work.
The church had enormous power. Religious leaders told the king and nobles, as well as the common people, what god wanted. Since people in the Middle Ages feared god, most of the time everyone from the king on down did what the church, through its religious leaders, told them to do.