Hadith #54
Sahih Bukhari
Allah's Messenger (ﷺ) said, "The reward of deeds depends upon the intentionand every person will get the reward according to what he hasintended. So whoever emigrated for Allah and His Apostle, then hisemigration was for Allah and His Apostle. And whoever emigrated forworldly benefits or for a woman to marry, his emigration was for whathe emigrated for."