I heard the Messenger of Allah ﷺ say, "Were it not for the emigration, I would be a man of the Ansar. And if the people took one valley or mountain pass, I would go with the Ansar."
قال وسمعت رسول الله ﷺ يقول لولا الهجرة لكنت امرأ من الأنصار ولو سلك الناس واديا أو شعبا لكنت مع الأنصار
Its isnad is hasan. The hadith was narrated by Tirmidhi 5/586 no. 3613, who graded it hasan, and Ibn Majah 2/1443 no. 4314, and Hakim graded it sahih 1/71 no. 240 (Dar al-Fikr edition).