The shaykh was asked about visiting graves.
He replied:
Returning to the grave after burial is not recommended. Rather, what is recommended at burial is to stand by the deceased’s grave and supplicate that he be granted steadfastness. Abū Dāwūd narrated in his Sunan that the Prophet, may Allah bless him and grant him peace,
“would stand by the grave after burying one of his Companions and say: ‘Ask that he be granted steadfastness, for he is now being questioned.’”
This is included in the meaning of Allah’s words:
“And never pray over any of them who dies, nor stand at his grave.”
When Allah forbade His Prophet, may Allah bless him and grant him peace, to offer the funeral prayer over the hypocrites or stand by their graves, the implication by contrast was that the funeral prayer should be offered over a believer before burial and that one should stand by his grave after burial. Thus, the prescribed practice of visiting the deceased to supplicate for them and seek forgiveness for them is a form of this prescribed standing by the grave.