یٰۤاَیُّہَا الَّذِیۡنَ اٰمَنُوۡا لَا تَتَّخِذُوۡا عَدُوِّیۡ وَ عَدُوَّکُمۡ اَوۡلِیَآءَ تُلۡقُوۡنَ اِلَیۡہِمۡ بِالۡمَوَدَّۃِ وَ قَدۡ کَفَرُوۡا بِمَا جَآءَکُمۡ مِّنَ الۡحَقِّ ۚ یُخۡرِجُوۡنَ الرَّسُوۡلَ وَ اِیَّاکُمۡ اَنۡ تُؤۡمِنُوۡا بِاللّٰہِ رَبِّکُمۡ ؕ اِنۡ کُنۡتُمۡ خَرَجۡتُمۡ جِہَادًا فِیۡ سَبِیۡلِیۡ وَ ابۡتِغَآءَ مَرۡضَاتِیۡ ٭ۖ تُسِرُّوۡنَ اِلَیۡہِمۡ بِالۡمَوَدَّۃِ ٭ۖ وَ اَنَا اَعۡلَمُ بِمَاۤ اَخۡفَیۡتُمۡ وَ مَاۤ اَعۡلَنۡتُمۡ ؕ وَ مَنۡ یَّفۡعَلۡہُ مِنۡکُمۡ فَقَدۡ ضَلَّ سَوَآءَ السَّبِیۡلِ ﴿۱﴾
1. O believers! Do not take My enemy and your enemy as trusted allies, conveying to them (secret news of the Prophet (blessings and peace be upon him) and the believers) because of your intimate affection (with them). (In contrast,) they have rejected the truth that has come to you, expelling the Messenger (blessings and peace be upon him) and you (from your homeland) simply because you believe in Allah, your Lord. If you have emigrated (from Mecca), striving in My path and seeking My good pleasure (then how can you take them as trusted allies)? You secretly disclose (the believers’ news) to them because of your intimate affection, while I know best whatever you conceal and whatever you reveal. And whoever among you does this has certainly strayed from the right way.*
* This verse was reportedly revealed concerning Hatib b. Abi Balta‘a, who sent a letter to the Quraysh of Mecca that was later intercepted by the efforts of some Companions. This letter contained information about the Prophet’s plan of marching upon Mecca. During the interrogation, he told the Prophet (blessings and peace be upon him) that he did it because he had allied with the Quraysh to obtain assistance from them. Hence, this commandment prohibited choosing an alliance with the disbelievers over the alliance of the Prophet (blessings and peace be upon him) and the believers.
يا أيها الذين آمنوا لا تتخذوا عدوي وعدوكم أولياء تلقون إليهم بالمودة وقد كفروا بما جاءكم من الحق يخرجون الرسول وإياكم أن تؤمنوا بالله ربكم إن كنتم خرجتم جهادا في سبيلي وابتغاء مرضاتي تسرون إليهم بالمودة وأنا أعلم بما أخفيتم وما أعلنتم ومن يفعله منكم فقد ضل سواء السبيل