How do we know who is in heaven?
The only people we can say for sure are in heaven ‘now’ - who are in full enjoyment of the beatific vision without need for purgation - are those the Church has identified as Saints.
Their lives and character are exhaustively investigated, and there have to have been miracles accredited to their intercession.
There are bound to be very many people who have died who are Saints in the fullest sense, who nevertheless we just don’t know enough about to formally declare them as Saints.
For the great majority of those who have died: it is prudent and charitable to assume that they are not yet fully possessed of God, and to pray for their souls.
Hope this is helpful.