Mishkat al-Masabih 1593
وَعَن عبد الله بن عَمْرو قَالَ ك تُوُفِّيَ رَجُلٌ بِالْمَدِينَةِ مِمَّنْ وُلِدَ بِهَا فَصَلَّى عَلَيْهِ النَّبِيِّ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ فَقَالَ: «يَا لَيْتَهُ مَاتَ بِغَيْرِ مَوْلِدِهِ» . قَالُوا وَلِمَ ذَاكَ يَا رَسُولَ اللَّهِ؟ قَالَ: «إِنَّ الرَّجُلَ إِذَا مَاتَ بِغَيْرِ مَوْلِدِهِ قِيسَ لَهُ مِنْ مَوْلِدِهِ إِلَى مُنْقَطَعِ أَثَرِهِ فِي الْجَنَّةِ» . رَوَاهُ النَّسَائِيّ وَابْن مَاجَه
From ʿAbdullah ibn ʿAmr, who said: A man died in Madinah, one of those who had been born there, and the Prophet ﷺ prayed over him and said: "Would that he had died somewhere other than his birthplace!" They said: "And why is that, O Messenger of Allah?" He said: "When a man dies somewhere other than his birthplace, there is measured for him [a space] in Paradise from his birthplace to the place where his footsteps ended." Reported by an-Nasaʾi and Ibn Majah.