What are some of the acts of penance, which may lead, by Allah’s grace, to the forgiveness of sins?
There are a number of acts, which Allah has promised, will serve as act of penance where a person will be forgiven their sins, if Allah chooses to do so, and obviously if these acts are done sincerely. And actually, they are most of our acts of worship, for example, the Prophet (ﷺ) has said:
“The obligatory prayer of the one who properly performs wudhu, as Allah the Exalted enjoined on him, will be expiation for sins committed between them.”
From salah to salah, if a person does wudhu properly, then those prayers will serve as expiations for the sins done between them. But again, this is not with a plan ahead; “I am going to do this sin and I have Asr prayer to make, so Insha’Allah, Allah is going to forgive me of my sin.” No, this is where a person does a sin and sincerely regrets doing the sin, and then from prayer to prayer, sins are forgiven.
Also, Prophet Muhammad (ﷺ) has said:
“When the time for a prescribed prayer arrives and a person performs wudhu well and humbly, offers prayer with proper bind, he is to be expiated for his past sins, as long as they are not major sins, and that is for all time.”
The sins that are forgiven by the prayers are not any sin that you do, but the minor sins. Major sins require repentance.
Also the Prophet (ﷺ) has said that from Friday prayer to Friday prayer, it is forgiveness for sins. He (ﷺ) said:
“If anyone performs wudhu well, then comes to Friday prayer, listens and keeps silent, his sins between them and the next Jumu'ah plus those of three extra days will be forgiven. But he would play with pebbles as cause and interruption.”
Likewise, praying on the night of power in Ramadan, Prophet Muhammad (ﷺ) said:
“All the previous sins of anyone who gets up for prayer during the night of power, Laylatul Qadr, out of faith and seeking its reward from his Lord will be forgiven.”
Furthermore, he said:
“All the previous sins of anyone who fasts the month of Ramadan out of faith and seeking his reward from his Lord will be forgiven.”
Again, all righteous deeds have this quality of removing sin. As Allah said in the Qur'an:
“Good deeds erase evil deeds.” 
So these details which Prophet Muhammad (ﷺ) is giving us are further details about how these good deeds will erase sins. He (ﷺ) also said:
“Whoever makes pilgrimage to His house, the Ka'bah, and does not have sexual relation with his wife while in the state of ihram, and does not commit sin during the hajj, will return sinless the way that his mother gave birth to him.”
That is the power of hajj. But that again should not be looked at as something you plan for. Unfortunately, this has become a common concept in the Muslim world today. So a young person wants to make hajj, they are able to do it, they have the money and the means, but the parents say to him, “No, you are still young, still committing sins. Wait until you get old. You know, when you cannot commit any more sin, you are now an old man, now it is time to go make hajj, to clean everything up.” No, hajj is required as soon as you are able. So each and every one of us should go and make hajj once their ability is there. And also Prophet Muhammad (ﷺ) has said that if the Islamic legal punishment like the hadd is applied; it comes to a person and the person is patient with it; it becomes a means also of expiation from sin.
So looking at all of these practices that can erase sin, we say that basically all of our righteous deeds can erase sins. How many sins, to what extent, etc. the Prophet (ﷺ) has given us the details, but the bottom line is sincere worship of God. As a sincere and good deed will erase our sin, it is the means for earning Allah’s forgiveness.
So this is one of the impacts that we should take from this quality of Allah being the Oft-Forgiving, Al Ghafir, Al Ghaffar and Al Ghafur. That we have to seek out Allah’s forgiveness by doing the deed that He has commanded us to do. Righteous deeds erase evil deeds.
 [On the authority of Utmaan ibn Afaan. Sheikh Albani said Saheeh in Saheeh al Jaami (5755)]
 [Narrated by Muslim (228) on the authority of Utmann ibn Afaan]
 [Narrated by Muslim (857) on the authority of Abu Huraira]
 [Al Bukhari (2014) and Muslim (760)]
 [Qur’an 11:114]
 [AlBukhari (1521) and Muslim (1350)]< Back to Questions