Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
ibnmajah:116ʿAlī b. Muḥammad > Abū al-Ḥusayn Akhabaranī Ḥammād b. Salamah > ʿAlī b. Zayd b. Judʿān > ʿAdī b. Thābit > al-Barāʾ b. ʿĀzib

"We returned with the Messenger of Allah from his Hajj that he had performed, and we stopped at some point on the road. He commanded that prayer should be performed in congregation, then he took the hand of 'Ali and said: 'Am I not dearer to the believers than their own selves?' They said: 'Yes indeed.' He said: 'Am I not dearer to every believer than his own self?' They said: 'Yes indeed.' He said: 'This man is the friend of those whose master I am.' O Allah, take as friends those who take him as a friend, and take as enemies those who take him as an enemy.'"  

ابن ماجة:١١٦حَدَّثَنَا عَلِيُّ بْنُ مُحَمَّدٍ حَدَّثَنَا أَبُو الْحُسَيْنِ أَخَبَرَنِي حَمَّادُ بْنُ سَلَمَةَ عَنْ عَلِيِّ بْنِ زَيْدِ بْنِ جُدْعَانَ عَنْ عَدِيِّ بْنِ ثَابِتٍ عَنِ الْبَرَاءِ بْنِ عَازِبٍ قَالَ

أَقْبَلْنَا مَعَ رَسُولِ اللَّهِ ﷺ فِي حَجَّتِهِ الَّتِي حَجَّ فَنَزَلَ فِي الطَّرِيقِ فَأَمَرَ الصَّلاَةَ جَامِعَةً فَأَخَذَ بِيَدِ عَلِيٍّ فَقَالَ أَلَسْتُ أَوْلَى بِالْمُؤْمِنِينَ مِنْ أَنْفُسِهِمْ قَالُوا بَلَى قَالَ أَلَسْتُ أَوْلَى بِكُلِّ مُؤْمِنٍ مِنْ نَفْسِهِ قَالُوا بَلَى قَالَ فَهَذَا وَلِيُّ مَنْ أَنَا مَوْلاَهُ اللَّهُمَّ وَالِ مَنْ وَالاَهُ اللَّهُمَّ عَادِ مَنْ عَادَاهُ  


See similar narrations below:

Collected by Aḥmad
ahmad:18479ʿAffān > Ḥammād b. Salamah > ʿAlī b. Zayd > ʿAdī b. Thābit > al-Barāʾ b. ʿĀzib

[Machine] We were with the Messenger of Allah ﷺ on a journey, and we stopped at Ghadeer Khumm. Then the call for prayer was made, announcing the congregational prayer. A place under two trees was cleared for the Messenger of Allah ﷺ to pray Dhuhr. He took the hand of Ali and said, "Do you not know that I have more authority over the believers than they have over themselves?" They replied, "Yes, indeed." He said, "Do you not know that I have more authority over every believer than they have over themselves?" They responded, "Yes, indeed." Then, he held Ali's hand and said, "Whoever has me as their master, Ali is also their master. O Allah, be a friend to whoever befriends him and an enemy to whoever fights against him." Umar met him afterward and said, "Congratulations, O son of Abu Talib! You have become the master of every believer, male and female, both in the morning and the evening."  

أحمد:١٨٤٧٩حَدَّثَنَا عَفَّانُ حَدَّثَنَا حَمَّادُ بْنُ سَلَمَةَ أَخْبَرَنَا عَلِيُّ بْنُ زَيْدٍ عَنْ عَدِيِّ بْنِ ثَابِتٍ عَنِ الْبَرَاءِ بْنِ عَازِبٍ قَالَ

كُنَّا مَعَ رَسُولِ اللهِ ﷺ فِي سَفَرٍ فَنَزَلْنَا بِغَدِيرِ خُمٍّ فَنُودِيَ فِينَا الصَّلَاةُ جَامِعَةٌ وَكُسِحَ لِرَسُولِ اللهِ ﷺ تَحْتَ شَجَرَتَيْنِ فَصَلَّى الظُّهْرَ وَأَخَذَ بِيَدِ عَلِيٍّ فَقَالَ أَلَسْتُمْ تَعْلَمُونَ أَنِّي أَوْلَى بِالْمُؤْمِنِينَ مِنْ أَنْفُسِهِمْ؟ قَالُوا بَلَى قَالَ أَلَسْتُمْ تَعْلَمُونَ أَنِّي أَوْلَى بِكُلِّ مُؤْمِنٍ مِنْ نَفْسِهِ؟ قَالُوا بَلَى قَالَ فَأَخَذَ بِيَدِ عَلِيٍّ فَقَالَ مَنْ كُنْتُ مَوْلَاهُ فَعَلِيٌّ مَوْلَاهُ اللهُمَّ وَالِ مَنْ وَالَاهُ وَعَادِ مَنْ عَادَاهُ قَالَ فَلَقِيَهُ عُمَرُ بَعْدَ ذَلِكَ فَقَالَ لَهُ هَنِيئًا يَا ابْنَ أَبِي طَالِبٍ أَصْبَحْتَ وَأَمْسَيْتَ مَوْلَى كُلِّ مُؤْمِنٍ وَمُؤْمِنَةٍ