Bara bin Azib reported,

The Prophet ﷺ said regarding the Ansar, "None loves them but a believer, and none hates them but a hypocrite. Whoever loves them, Allah loves him, and whoever hates them, Allah hates him."Shuba said, I asked Adi, "Did you hear this from al-Bara?"He replied, "He narrated it to me directly."

Muslim 237

Sahih

و حدثني زهير بن حرب قال حدثني معاذ بن معاذ ح و حدثنا عبيد الله بن معاذ واللفظ له حدثنا أبي حدثنا شعبة عن عدي بن ثابت قال

سمعت البراء يحدث

عن النبي ﷺ أنه قال في الأنصار لا يحبهم إلا مؤمن ولا يبغضهم إلا منافق من أحبهم أحبه الله ومن أبغضهم أبغضه الله قال شعبة قلت لعدي سمعته من البراء قال إياي حدث

مسلم 237صحيح
Contents
Reference
Commentary
Ayat
Collection
Sahih Muslim
Book
Faith
Chapter
Evidence that loving the Ansar and Ali رضي الله عنهم is from faith and its signs, and hating them is from the signs of hypocrisy
Numbering
Darussalam 237
Muslim 237