The Catholic Church teaches that purgatory is a final stage of purification for many souls desiring to enter the gates of Heaven. It is called by some the “washroom” of Heaven, where souls go who want to “clean themselves up” before entering total union with God for all eternity.
The Church encourages us to pray for these souls, believing our prayers can somehow shorten the time spent in this stage of purification.
Here is a prayer from the Raccolta that directs our prayers to that soul who is closest to Heaven and is on the verge of entering eternal bliss.
O Lord God Almighty, I pray Thee, by the Precious Blood which Thy Divine Son Jesus shed in His cruel scourging, deliver the souls in purgatory, and that soul especially amongst them all which is nearest to its entrance into Thy glory; that so it may forthwith begin to praise and bless Thee for ever. Amen.