General Context
This verse follows the declaration that striving benefits the one who strives and that Allah has no need of any of the worlds. It opens the door to glad tidings for those who did not leave faith as a claim hanging in the air, but proved it true by doing righteous deeds, stood firm through trial, and struggled against their own selves on the path to Allah. It is as though the passage, having told the believer, “Your striving is for your own sake, not for any benefit that accrues to Allah,” now tells him, “Even so, none of your striving will be lost with Allah. Rather, your Lord will bestow two great favors on you: He will erase your misdeeds and reward you according to the best of what you did.”
This is one of the most refreshing verses of hope at the opening of Surah al-ʿAnkabūt, for it comes after a stern passage marked by trial, a sifting of people, warning, and striving. The surah begins by posing the question of trial: Will people be left to say that they believe without being put to the test? It then explains that Allah tested those before them, warns those who do evil, reassures those who hope to meet Allah, and declares that striving benefits the one who strives. Now this verse comes to say that however hard the road, it ends in mercy; however painful the striving, its fruit is forgiveness and a generous reward; and even if the believer stumbles along the way, Allah meets him not with a bare reckoning alone, but with a grace that wipes away misdeeds and magnifies good deeds.
Sayyid Quṭb said: “Let the believers who do good rest assured of what awaits them with Allah.” — Fī Ẓilāl al-Qurʾān — Sayyid Quṭb Ibrāhīm al-Shādhlī. These words can serve as a key to the verse. After hearing of trial and striving, believers who do good need a reassurance that fills the heart—not a flabby reassurance that invites them to sit back, but one that moves them to act, knowing that Allah lets no one’s work go to waste, overlooks no tear shed in patience, and leaves no sincere striving unrewarded. They do not strive because Allah needs them. They strive because Allah opened the door to their salvation, then promised to purify their past, honor their present, and reward them according to the best of what they did.
Rhetorical Outpourings
The verse opens with the relative construction ﴿وَٱلَّذِينَ ءَامَنُواْ وَعَمِلُواْ ٱلصَّـٰلِحَٰتِ﴾ (“And those who believe and do righteous deeds” · 29:7). The relative clause brings together two foundations that cannot be separated in the formation of the believer’s character: faith and righteous action. Faith is the root that feeds the heart with certainty, and righteous action is the fruit that shows the root is alive. In the context of Surah al-ʿAnkabūt, this pairing is more than a familiar expression. It is a practical answer to trial: one sign that their faith is sincere is that they hold fast to the foundations of their religion in adversity, and those who do righteous deeds are the ones who prove their claim in the arena of life.
Al-Ṭabarī said of these people: “Their faith proved sound when Allah tried them and put them to the test.” — Jāmiʿ al-Bayān ʿan Taʾwīl Āy al-Qurʾān — Muḥammad ibn Jarīr al-Ṭabarī. This observation shows that the faith in this verse is faith that has been tested, not merely inherited or professed. It passed through fire and came out stronger. This binds the verse closely to what precedes it: those who believed and did righteous deeds are the ones who strove for their own sake, stood firm under trial, and neither made misdeeds their way of life nor let the respite they were given deceive them and govern their judgment.
Then comes the emphatic clause: ﴿لَنُكَفِّرَنَّ عَنۡهُمۡ سَيِّـَٔاتِهِمۡ﴾ (“We will surely remove from them their misdeeds” · 29:7). The lām (ل), together with the heavy nūn of emphasis (نّ), gives the promise a decisive ring, as though mercy here were a solemn pledge from Allah to His servants who believe and do good. To expiate means, at root, to cover and remove, not merely to overlook in words. Allah erases the trace of the misdeed, covers its shame, and removes its consequences, so that it no longer stands between the servant and a new future with his Lord. Al-Samʿānī said: “Expiation is the removal of a misdeed by a good deed.” — Tafsīr al-Qurʾān — Manṣūr ibn Muḥammad al-Samʿānī. This meaning is especially fitting: good deeds are not mere adornments in the servant’s record. They have a purifying effect, erasing the darkness of misdeeds by Allah’s permission.
The second promise is then joined to the first: ﴿وَلَنَجۡزِيَنَّهُمۡ أَحۡسَنَ ٱلَّذِي كَانُواْ يَعۡمَلُونَ﴾ (“and will surely reward them according to the best of what they used to do.” · 29:7). The first promise wards off harm, and the second bestows grace. The first is the expiation of misdeeds; the second is reward according to the best of one’s deeds. Here divine generosity is shown in full: Allah does not merely pardon, but rewards; He does not merely erase the past, but raises what lies ahead; He does not deal with His servant on the basis of the sum of his weaknesses and shortcomings, but rewards him for the finest sincerity and goodness in the life he has led.
Ibn ʿĀshūr explained the subtlety of the expression: “The implied wording is: ‘And We shall surely give them a better recompense.’” — al-Taḥrīr wa-l-Tanwīr — Muḥammad al-Ṭāhir Ibn ʿĀshūr. The meaning is not that Allah rewards them for only some of their deeds and leaves others aside, but that the whole recompense is weighed on the scale of goodness and grace, measured by the best of what they did. This is an outpouring of generosity: if the servant were called to account for his lowest moments, he would perish; if he were rewarded according to the best of what he did, he would be raised and honored.
One subtle feature of the composition is that the verse does not simply say “لنكفرن سيئاتهم” (“We shall surely expiate their misdeeds”). Rather, it says ﴿عَنۡهُمۡ﴾ (29:7), suggesting that their misdeeds were a burden clinging to them, which Allah takes off them and removes from their path, freeing them from its weight. Nor does it say “ولنجزينهم بما كانوا يعملون” (“And We shall surely recompense them for what they used to do”). Rather, it says ﴿أَحۡسَنَ ٱلَّذِي كَانُواْ يَعۡمَلُونَ﴾ (“the best of what they used to do” · 29:7). It is as though Allah chooses the most beautiful, the purest, and the most sincere of their deeds and makes those the measure of their reward. This is the mercy of One who knows the servant’s weakness yet loves his sincerity.
Interpretive and Reflective Outpourings
In this verse a profound aspect of mercy after striving comes to light: Allah does not want the believer to remain a prisoner of his past if his faith is sincere and his conduct upright. A person sets out on the path to Allah with sins in his record, stumbles in his memory, and perhaps in his heart traces of an old ignorance, of past lapses of heedlessness, or of a human weakness that never leaves him. If he were told, “All of that will keep pursuing you,” he would break. But Allah tells him, “Believe, do righteous deeds, and struggle against your own self, and I will wipe away your misdeeds and reward you according to the best of what you did.”
Muqātil put it very briefly: “He rewards them for their good deeds and does not recompense them for their misdeeds.” — Tafsīr Muqātil ibn Sulaymān — Muqātil ibn Sulaymān. This captures the spirit of the whole verse: Allah deals with the servant with generosity, not by keeping track of every stumble. The believing servant is saved not because he has no misdeeds, but because he believed, acted, strove, and repented, and Allah responded by wiping away his misdeeds and granting him a good reward. This opens the door to hope without opening the door to complacency, for the promise is tied to faith and righteous action, not to a mere claim.
In explaining the forms recompense takes, al-Māturīdī said: “That He expiate their misdeeds by means of one kind of good deed, and that they be rewarded for the best of their good deeds.” — Taʾwīlāt Ahl al-Sunnah — Muḥammad ibn Muḥammad al-Māturīdī. There is a subtle insight here: good deeds have two effects. They purify by erasing misdeeds, and they elevate by raising the servant in rank. They are not mere numbers in a record, but a luminous life at work within the servant, erasing darkness and building light.
Here the believer should reflect on the fact that His words ﴿وَعَمِلُواْ ٱلصَّـٰلِحَٰتِ﴾ (“and do righteous deeds” · 29:7) are not a marginal addition to faith. The verse comes after His words ﴿وَمَن جَٰهَدَ﴾ (“And whoever strives” · 29:6), so the context points to righteous action as the form daily striving takes: praying on time, telling the truth when it is called for, being patient under trial, remaining chaste in the face of desire, keeping a pledge, treating Allah’s creatures with kindness, and standing firm in the truth. Righteous action is not merely a set of acts of worship isolated from the trials of life. It is faith put into practice in every facet of existence.
Al-Zamakhsharī conveyed the meaning of the verse in two broad possibilities: believers whose good deeds outweigh their misdeeds, or polytheists who came to faith and whose past deeds Allah erased. He said: “He expiates their misdeeds for them; that is, He cancels their punishment by means of the reward for their good deeds.” — al-Kashshāf ʿan Ḥaqāʾiq Ghawāmiḍ al-Tanzīl — Maḥmūd ibn ʿUmar al-Zamakhsharī. This breadth makes the verse a door for longtime and new believers alike: a door for the believer who stumbled and whose good deeds then prevailed, and a door for the one who was far away and then returned to Allah. In both cases, Allah does not make the past a grave for the future if faith and action are sincere.
One of the deepest things about the verse is that it gives the believer a new way to understand his relationship to his misdeeds. A misdeed is not an eternal fate, an indelible stain, or a wall that cannot be crossed. Rather, it is something Allah can wipe away if the servant comes with faith and righteous action. This does not make the misdeed any less dangerous, but it keeps it from turning into despair. Satan may first call a person to disobedience, then, once he falls into it, call him to despair. The Qur’an, on the other hand, opens another path: do good, strive, and return, for your Lord wipes away misdeeds and gives reward. This hope is to be read alongside the other texts of promise and warning: repentance is a door to forgiveness for grave sins; the rights of others are not extinguished by a righteous deed alone; and expiation through good deeds is not permission to persist in disobedience.
Spiritual Outpourings
This is one of the tenderest verses of hope for a heart weighed down by its sins. It tells the heart: Allah does not reduce your story to your worst moments or see you only through your stumble. Rather, He opens the door of faith and righteous action to you, then promises to erase your misdeeds and reward you for the best of what you did. What generosity is this? What mercy it is for Allah to deal with His weak servant according to the best in him, not the worst that has come from him, if he is sincere and turns to Him.
The believer on the path of striving is not free of shortcomings. He may falter and then rise, sin and then repent, or find his deeds mingled with some listlessness or heedlessness, but he does not leave the path. Here the verse brings glad tidings to those who walk the path, not those who merely claim to; it brings glad tidings to those who believe and do righteous deeds, not those who are content to wish. When the servant joins faith to action, he finds that Allah covers his faults, wipes away his misdeeds, and deals generously with him.
Al-Biqāʿī pointed to this meaning when he said: “…that a person, however hard he strives, is bound to stumble, because he is formed with shortcomings.” — Naẓm al-Durar fī Tanāsub al-Āyāt wa-l-Suwar — Ibrāhīm ibn ʿUmar al-Biqāʿī. These words lay balm on the wound of the human soul. Allah knows that humans are formed with shortcomings, and so He opened the door to expiation. He did not make the stumble the end. After it He provided prayer, repentance, a good deed, patience, righteous action, and striving that lifts the servant up again.[1]
In this spiritual outpouring, righteous action becomes a path to healing. Good deeds are not merely burdensome duties, but salves for the soul: they erase, they purify, and they put our inner lives back in order. Every sincere prostration washes away a little of the dust on the heart, every act of charity puts out a fire, every act of remembrance awakens a meaning, every act of pardon breaks a piece of pride, and every act of patience mends a crack. And so the path of righteous action becomes a long road to spiritual recovery, not just a list of duties.
One of the most beautiful ways the text opens the door to hope is that it does not simply say that Allah will reward them “بأعمالهم” (“for their deeds”). Rather, it says ﴿أَحۡسَنَ ٱلَّذِي كَانُواْ يَعۡمَلُونَ﴾ (“the best of what they used to do” · 29:7). It is as though Allah honors His servant by attending to his moments of purity, his acts of devotion, and the occasions when he stood true, making these the defining mark of his reward. How wonderful for the servant to know that moments no one else saw are kept for him with Allah, and that a hidden tear, a desire resisted, patience in solitude, or a kindness done without expecting a reward may be among the best of what he did, and that Allah may honor him for it.
The qualification given in Ṣaḥīḥ Muslim, no. 233, is that major sins must be avoided. The good news that sins are expiated should therefore not be taken to mean that repentance is no longer required or that the rights of others are set aside. https://sunnah.com/muslim:233c ↩︎
Psychological Outpourings
This verse addresses the knot of guilt in the believer’s soul. When a person does wrong, he may fall into either of two dangerous extremes: taking the sin so lightly that he repeats it without shame, or despairing so deeply that he thinks there is no point in returning. The Qur’an teaches him a third way: do not take it lightly, and do not despair. Believe, do righteous deeds, and struggle against your own self, for Allah wipes away misdeeds and rewards according to the best of one’s deeds. Sin is faced with acknowledgment, repentance, and action, and someone weighed down by guilt may also need psychological support.
Speaking of freedom from the past, Ḥusayn Faḍlallāh said: “He does not want people to remain in the grip of a guilt complex.” — Min Waḥy al-Qurʾān — Muḥammad Ḥusayn Faḍlallāh. Psychologically, this statement is of great importance. For some people, it is not the sin alone that destroys them, but the complex that takes shape after it, when they think they are no longer fit to go on or that their past is stronger than Allah’s mercy. The verse breaks the grip of this complex not by excusing the wrong, but by opening up the prospect of righteous deeds that erase what came before and lift a person up.
Psychologically, the verse also reshapes memory. A troubled past can become an inner prison. Whenever a person tries to get back up, they call that past to mind, and it says to them: You are not worthy. Look at what you did, and what you did after that. The Qur’anic promise, by contrast, says: ﴿لَنُكَفِّرَنَّ عَنۡهُمۡ سَيِّـَٔاتِهِمۡ﴾ (“We will surely remove from them their misdeeds” · 29:7). In other words, the past does not have the last word if you are sincere with Allah in the present. The past may even become a lesson rather than a restraint; a reminder of weakness rather than a reason to despair; an incentive to humility rather than an obstacle to moving forward.
The verse also points to the soul’s need to be appraised by Allah with justice and mercy. A person may do a great deal, yet others see nothing but their mistake, forget their good deeds the moment they stumble, or judge them by their worst moments. Allah, by contrast, knows it all, wipes away sins, and rewards the servant according to the best of what they did. This gives the soul a deep balance: it does not get carried away when people praise it, nor does it collapse when they are harsh. For the true measure is with Allah, and He is more generous, more knowing, and more just.
One of the verse’s greatest effects on the soul is that it turns righteous action into hope. Whenever believers do a good deed, they feel that they are not merely adding a white mark: they are also healing a dark stain left by the past and opening for themselves a door to greater reward. Obedience is no longer a matter of dry duty but of living hope. They pray because they need to be washed clean. They give charity because they need to be purified. They endure patiently because they hope their patience will be among the best deeds for which they are rewarded. In this way, obedience becomes a work of restoring the soul.
Pedagogical Outpourings
In education, this verse establishes a great principle: there is no sound education without both self-examination and hope. The preceding verses called misguided assumptions to account, established the reality of trial, warned wrongdoers, and commanded striving. Then came this verse to keep education from turning into pressure with no prospect of relief. Believers need to know what the road will cost them, but they also need to see the mercy that awaits them at its end. They need to hear: Strive. And they need to hear: Allah will wipe away your sins and reward you according to the best of what you do.
People should therefore be taught that righteous action is not some flawless, angelic perfection, but a lifelong journey of making corrections along the way. A person stumbles but does not justify the stumble. They grow weak but do not stop doing good. They repent, then build on their repentance with righteous deeds. If we teach people that a mistake is the end of the road, we foster despair. If we teach them that mistakes do not matter, we foster heedlessness. The Qur’an, by contrast, teaches them that wrongs are erased through faith, righteous action, repentance, and striving.
In interpreting the verse as referring to the emigrants, Ibn ʿAṭiyyah said: “It speaks of the believers who emigrated, who stand in the highest rank of those who hasten to Allah Most High.” — al-Muḥarrar al-Wajīz fī Tafsīr al-Kitāb al-ʿAzīz — ʿAbd al-Ḥaqq ibn Ghālib Ibn ʿAṭiyyah. This connects the verse with teaching people to take the initiative. These believers were not content to keep faith in their hearts. They hastened to act on what it demanded, bore its burdens, and left behind what was familiar for the sake of Allah. The verse holds up those who hasten to Allah as examples to stir those who lag behind, and says to them: The road is open and the reward is great, so do not sit still under the weight of trial or of the past.
Part of education, too, is teaching believers that Allah rewards the best, so they should seek what is best in their own deeds. This does not mean giving in to obsessive doubts or pursuing unattainable perfection. It means refining their intentions, improving their deeds, and seeking sincerity. If Allah rewards people according to the best of what they did, then let the servant give some care to doing what is best: the best prayer they can offer, the sincerest repentance they can muster, the purest act of charity, the most merciful way of treating others, and the firmest stand in a trial. Seeking what is best trains the will to aim higher.
The verse also holds a lesson for educators and those who call people to Allah: Open the doors of return. Do not address people as though their past condemns them forever, or as though sins cannot be wiped away. Instill in them the conviction that righteous action is a new beginning, that Allah is too generous to turn away anyone who is sincere with Him, and that those who repent, believe, and do righteous deeds do not remain slaves to their old self-image. The Qur’an’s work of education does not leave people crushed beneath their sins; it raises up people who repent, act, and hope for Allah’s bounty.
Contemporary Outpourings
In our time, many people feel the weight of the past: documented mistakes, painful memories, unhealthy relationships, hidden sins, or a former life lived far from Allah. This memory can turn into a negative identity that dogs a person: I’m no good. I’m finished. I can’t become someone new. The verse comes to say: No, you can begin with faith and righteous action. Allah does not want to lock His servant in the past if the servant returns to Him. Rather, He opens a way for their sins to be wiped away and their deeds to be rewarded.
How deeply people today need this mercy, for they live in a world that does not easily forget. People save pictures, platforms keep a record of missteps, and communities may go on reminding a person of a mistake for a long time. But when a servant is sincere with Allah, He wipes away their sins and opens up a future shaped not by what people remember, but by Allah’s mercy. This does not mean evading the consequences of infringing on others’ rights or failing in one’s responsibilities. It means that Allah’s door does not close merely because people have closed theirs.
The verse also reshapes what it means to achieve something as a person of faith. The world measures people by their greatest visible successes or their most conspicuous scandals. Allah, by contrast, deals with believers who act according to a different measure: He wipes away sins and rewards the best deeds. A person’s worth before Allah is not confined to how others see them or to their mistakes, whether others know of them or not. It lies, rather, in the sincerity of their faith, their righteous deeds, their striving, and the best of what they have done for Allah.
In daily life, the verse opens a wide door to action: Every good deed is a chance to erase a bad one, and every righteous act is a brick in the building of a new destiny. So do not look down on any act of kindness or think any act of obedience too small. Do not say: What can this little good deed do in the face of all that has gone before? It is Allah who wipes away sins; it does not depend on how great the deed seems to the one who does it. Allah may place great sincerity in a simple act, so that it becomes one of the best things the servant has done, and reward them for it with bounty they could never have imagined.
In an age that tends toward self-punishment on the one hand and self-justification on the other, the verse offers a beautiful balance: Do not beat yourself down until you despair, and do not excuse your sin until you go on sinning. Believe, act, set things right, strive, and let Allah’s bounty do in your record of deeds what you cannot do yourself. Allah wipes away sins, Allah rewards according to the best deeds, and Allah knows best who was sincere in the trial, who returned after sinning, and who carried in their heart a genuine desire to become a new servant.
And so the seventh verse pours the light of hope over the opening of Surah al-ʿAnkabūt after the discussion of trial and striving. It tells believers: The road is not merely a test, nor striving that bears no fruit, nor patience that dissolves into nothing. There is a generous Lord who wipes away sins, magnifies good deeds, and rewards the servant according to the best of what they did. Those who understand this verse do not make light of their sins, but neither do they despair of forgiveness. They do not become vain about their deeds, but they hope for their Lord’s bounty. And they do not give up striving, for they know that every sincere step along Allah’s path comes back to them as light, forgiveness, and elevation. Those who believe and do righteous deeds are not angels who never err. They are servants who have been true to the path: Allah’s bounty has gone ahead of them to wipe away their sins, and His generosity has caught up with them with the finest reward.
﴿وَٱلَّذِينَ ءَامَنُواْ وَعَمِلُواْ ٱلصَّٰلِحَٰتِ لَنُكَفِّرَنَّ عَنۡهُمۡ سَيِّـَٔاتِهِمۡ وَلَنَجۡزِيَنَّهُمۡ أَحۡسَنَ ٱلَّذِي كَانُواْ يَعۡمَلُونَ﴾ (7)
And those who believe and do righteous deeds - We will surely remove from them their misdeeds and will surely reward them according to the best of what they used to do.