HAKIM 1393:
from Anas b. Mālik —
[Machine] The Messenger of Allah ﷺ said, "I used to prohibit you from visiting graves, but now I encourage you to do so, for it softens the heart, brings tears to the eyes, and reminds you of the hereafter. However, do not say anything that will bring harm."
الحاكم ١٣٩٣:
عن انس بن مالك —
قَالَ رَسُولُ اللَّهِ ﷺ «كُنْتُ نَهَيْتُكُمْ عَنْ زِيَارَةِ الْقُبُورِ أَلَا فَزُورُوهَا فَإِنَّهُ يُرِقُّ الْقَلْبَ وَتُدْمِعُ الْعَيْنَ وَتُذَكِّرُ الْآخِرَةَ وَلَا تَقُولُوا هُجْرًا»
hadithunlocked.com