Praise be to Allah, and peace and blessings be upon the Messenger of Allah.
This objection can be answered from several angles:
First: The punishment of the grave is established by the Islamic texts.
Allah تعالى says concerning the people of Pharaoh:
“The Fire—they are exposed to it morning and evening, and on the Day the Hour is established: ‘Admit the people of Pharaoh into the harshest punishment.’” [Ghafir: 46]
The Prophet ﷺ also said:
“Were it not that you would stop burying one another, I would ask Allah to let you hear some of the punishment of the grave that I hear.” Narrated by Muslim.
And regarding the believer, he ﷺ said:
“His grave will be made spacious for him as far as his sight can reach.” Agreed upon.
Therefore, these authentic texts cannot be rejected merely on the basis of rational speculation or what appears to the senses.
Second: The conditions of the grave belong to the unseen.
The punishment and bliss of the grave are related to the realm of Barzakh. Their effects do not necessarily have to appear on the body in the manner we know from worldly life. If these matters were tangible and visible to everyone, belief in them would no longer be belief in the unseen.
Third: The deceased may experience forms of bliss or punishment that the living cannot perceive.
An example of this is what a person experiences in a dream. Someone may see himself in a spacious or confined place, or feel that he is moving or being struck, while those around him see none of this, even though his body remains lying on his bed.
Therefore, the fact that the effects of punishment are not visible when a grave is opened does not prove that the punishment does not exist. The conditions of the Barzakh differ from those of worldly life, and whatever Allah and His Messenger ﷺ have informed us of must be believed and accepted.
When it comes to matters of the unseen, our duty is to say:
“We hear and we obey; we believe and we affirm the truth.”
And Allah تعالى knows best.