Sahih Muslim 976 b
Narration text is preserved in its supplied Arabic and English. Translated interfaces and reading guides do not add narration translations in other languages.
اسْتَأْذَنْتُ رَبِّي فِي أَنْ أَسْتَغْفِرَ لَهَا فَلَمْ يُؤْذَنْ لِي وَاسْتَأْذَنْتُهُ فِي أَنْ أَزُورَ قَبْرَهَا فَأُذِنَ لِي فَزُورُوا الْقُبُورَ فَإِنَّهَا تُذَكِّرُ الْمَوْتَ "
Abu Huraira reported:
The Apostle of Allah (ﷺ) visited the grave of his mother and he wept, and moved others around him to tears, and said: I sought permission from my Lord to beg forgiveness for her but it was not granted to me, and I sought permission to visit her grave and it was granted to me so visit the graves, for that makes you mindful of death.
Full reference and source
Sahih Muslim 976 b In-book : Book 11, Hadith 135 USC-MSA web (English) : Book 4, Hadith 2130 (deprecated)
View source on Sunnah.com (opens in a new tab)