The Messenger of Allah ﷺ said, "When Allah loves a servant, He calls out to Jibreel, 'I love so-and-so, so love him.' Then Jibreel calls out in the heavens, and love for that person descends among the people of the earth. This is the meaning of Allah's words, 'Indeed, those who believe and do righteous deeds, the Most Merciful will appoint for them affection' [Maryam 19:96]. And when Allah hates a servant, He calls out to Jibreel, 'I hate so-and-so.' Then Jibreel calls out in the heavens, and hatred for that person descends upon the earth."
حدثنا قتيبة حدثنا عبد العزيز بن محمد عن سهيل بن أبي صالح عن أبيه
أن رسول الله ﷺ قال إذا أحب الله عبدا نادى جبريل إني قد أحببت فلانا فأحبه قال فينادي في السماء ثم تنزل له المحبة في أهل الأرض فذلك قول الله {إن الذين آمنوا وعملوا الصالحات سيجعل لهم الرحمن ودا} وإذا أبغض الله عبدا نادى جبريل إني أبغضت فلانا فينادي في السماء ثم تنزل له البغضاء في الأرض
Muslim also narrated it in "Righteousness and Kinship," in the chapter "When Allah loves a servant, He commands Gabriel to love him, so he loves him and the people of heaven love him, then acceptance is placed for him on earth," Hadith 2637, from Qutayba, with the same chain. Bukhari also narrated it, Hadith 7485, from the hadith of Abdul-Rahman bin Abdullah bin Dinar, with the same chain.