“They occupy differing ranks before Allah”: that is, they hold differing ranks before Allah. Ibn Abbas, may Allah be pleased with him, said: This means that those who pursue Allah’s pleasure and those who incur wrath from Allah occupy different stations with Allah. Those who pursue Allah’s pleasure shall have a tremendous reward, while those who incur wrath from Allah shall have a painful punishment. “And Allah sees all that they do.”
“Indeed, Allah has graciously favored the believers by raising up among them a Messenger from among themselves, reciting to them His revelations, purifying them, and teaching them the Book and wisdom, although before that they were clearly astray. (164) When a calamity befell you, after you had inflicted one twice as great, you said, ‘How could this be?’ Say, ‘It is from your own selves.’ Surely Allah is Most Capable of everything. (165)”
“Indeed, Allah has graciously favored the believers by raising up among them a Messenger from among themselves.” It has been said that this refers to the Arabs, for there was no tribe among the Arab tribes with whom he did not have kinship ties, except Banu Tha‘laba. The evidence is Allah Most High’s saying: “He is the One Who raised among the unlettered a Messenger from among themselves.”
Others said that it refers to all the believers. The meaning of Allah Most High’s saying, “from among themselves,” is that he was one of them in faith and compassion, not in lineage. The evidence is Allah Most High’s saying: “There has certainly come to you a Messenger from among yourselves.” “Reciting to them His revelations, teaching them the Book and wisdom, and purifying them,” whereas before that—that is, before he was sent—they had been in clear error.
“When”: that is, when “a calamity befell you” at Uhud, “after you had inflicted one twice as great” on the day of Badr. This was because the polytheists killed seventy Muslims at Uhud, while the Muslims killed seventy of them at Badr and took seventy captive. “You said, ‘How could this be?’” That is: How did this killing and defeat befall us when we are Muslims and the Messenger of Allah, may Allah bless him and grant him peace, is among us? “Say, ‘It is from your own selves.’”
Ubaydah al-Salmani narrated from Ali, may Allah be pleased with him, who said: Gabriel came to the Prophet, may Allah bless him and grant him peace, and said, “Allah has disapproved of what your people did by taking ransom for the captives. He has commanded you to give them the choice between executing the captives or taking ransom from them, on the condition that an equal number of your men will be killed.” The Messenger of Allah, may Allah bless him and grant him peace, mentioned this to the people, and they said, “O Messenger of Allah, they are our clansmen and brothers. No; rather, we shall take ransom from them, thereby gaining strength to fight our enemy, though an equal number of us will be martyred.” [And seventy of them were killed at Uhud] (1)—seventy, equal to the number of captives taken at Badr. This is the meaning of Allah Most High’s saying: “Say, ‘It is from your own selves.’” (2) That is, because you took ransom and chose that your men be killed. “Surely Allah is Most Capable of everything.”