Al-Dahhak said: He comes between the disbeliever and obedience, and between the believer and disobedience.
Mujahid said: He comes between a person and his heart, so that he neither understands nor knows what he is doing.
Al-Suddi said: He comes between a person and his heart, so that he is unable either to believe or to disbelieve except by His permission.
It was also said: When the people were called to fight while they were in a state of weakness, they entertained misgivings and their hearts were troubled. They were therefore told: Fight in the way of Allah, and know that Allah comes between a person and his heart: He replaces fear with security and cowardice with courage. “And that to Him you will be gathered,” whereupon He will recompense you for your deeds.
Ahmad ibn Abd Allah al-Salihi informed us; Ahmad ibn al-Hasan al-Hiri narrated to us; Hajib ibn Ahmad al-Tusi narrated to us; Muhammad ibn Hammad narrated to us; Abu Mu'awiyah narrated to us, from al-A'mash, from Abu Sufyan, from Anas ibn Malik, may Allah be pleased with him, who said: The Messenger of Allah, peace and blessings be upon him, would frequently say, “O Turner of hearts, keep my heart steadfast upon Your religion.” They said, “O Messenger of Allah, we have believed in you and in what you have brought. Do you fear for us?” He said, “Hearts are between two of Allah’s fingers, and He turns them as He wills.” (1)
“And beware of a trial”—a test and affliction—“that will not afflict...” The phrase “that will not afflict” is not a straightforward conditional apodosis, for had it been one, the emphatic nūn would not have occurred in it. Rather, it is [a negation] (2), though it carries an element of conditional consequence, like His saying, Most High: “O ants! Enter your dwellings, lest Solomon and his troops crush you, unaware.” (Al-Naml, 27:18) Its intended sense is: Beware of a trial which, if you do not guard against it, will afflict you. It is like someone saying, “Get down from the mount, lest it throw you.” This is a response to a command expressed in the form of a prohibition; its meaning is: If you get down, it will not throw you.
The exegetes said: This verse was revealed concerning the Companions of the Messenger of Allah, peace and blessings be upon him. Its meaning is: Beware of a trial that will afflict both the wrongdoer and the one who has not done wrong.
Al-Hasan said: It was revealed concerning Ali, Ammar, Talhah, and al-Zubayr, may Allah be pleased with them. Al-Zubayr said: “For a long time we recited this verse without thinking that we were among those intended by it; then, behold, we were the ones meant by it”—referring to what took place on the Day of the Camel. (3)