Abdullah bin Masud reported,

The Prophet ﷺ said, "When the appointed time of death for one of you is set in a particular land, a need will arise that drives him to that very place. When he reaches the furthest point of his journey, Allah, glorified is He, takes his soul. Then on the Day of Resurrection the earth will say, 'My Lord, this is what You entrusted to me.'"

Azami 3449

Sahih

عن عبد الله بن مسعود

عن النبي ﷺ قال: إذا كان أجل أحدكم بأرض أوثبته إليها الحاجة، فإذا بلغ أقصى أثره قبضه الله سبحانه، فتقول الأرض يوم القيامة: رب هذا ما استودعتني.

الأعظمي 3449صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Funerals
Chapter
Patience in tribulation and illness
Section
Departing of a person to the land where his death was destined
Numbering
Jami al-Kamil 3449 (2nd edition)
Azami 3449