O believers! Do not take My enemies and yours as trusted allies, showing them affection even though they deny what has come to you of the truth. They drove the Messenger and yourselves out ˹of Mecca˺, simply for your belief in Allah, your Lord. If you ˹truly˺ emigrated1 to struggle in My cause and seek My pleasure, ˹then do not take them as allies,˺ disclosing secrets ˹of the believers˺ to the pagans out of affection for them, when I know best whatever you conceal and whatever you reveal. And whoever of you does this has truly strayed from the Right Way.
— Dr. Mustafa Khattab, the Clear Quran
O you who have believed, do not take My enemies and your enemies as allies,1 extending to them affection while they have disbelieved in what came to you of the truth, having driven out the Prophet and yourselves [only] because you believe in Allah, your Lord. If you have come out for jihād [i.e., fighting or striving] in My cause and seeking means to My approval, [take them not as friends]. You confide to them affection [i.e., instruction], but I am most knowing of what you have concealed and what you have declared. And whoever does it among you has certainly strayed from the soundness of the way.
— Saheeh International