"According to the grace of God given to me, like a wise master builder I laid a foundation, and another is building upon it. But each one must be careful how he builds upon it, for no one can lay a foundation other than the one that is there, namely, Jesus Christ. If anyone builds on this foundation with gold, silver, precious stones, wood, hay, or straw, the work of each will come to light, for the Day will disclose it. It will be revealed with fire, and the fire [itself] will test the quality of each one’s work. If the work stands that someone built upon the foundation, that person will receive a wage. But if someone’s work is burned up, that one will suffer loss; the person will be saved, but only as through fire." 1 Cor 3: 10-15
This passage
explicitly speaks of a process which occurs
after death, in which one may suffer loss and yet be saved.
There is no suffering or loss in heaven, so this process cannot be taking place in heaven. And there is no escape from hell, so it can't be happening in hell either.
Therefore, there is a third state, in which this purging of the works of wood, hay and straw takes place, and only those bound for heaven enter this third state. This is purgatory. It's right there,
explicitly taught by the Apostle Paul.