To be accepted, repentance requires giving up the sin and making amends, and Allah alone accepts repentance and forgives sins. These verses also speak of turning back to Allah in repentance (inabah), the command to repent joined to seeking forgiveness, sin committed in ignorance, and repentance that is no longer accepted at the moment of death.
Verses gathered from a topical index of the Quran, in Mushaf order; every verse is quoted in full.
And when adversity touches the people, they call upon their Lord, turning in repentance to Him. Then when He lets them taste mercy from Him, at once a party of them associate others with their Lord,
And when adversity touches man, he calls upon his Lord, turning to Him [alone]; then when He bestows on him a favor from Himself, he forgets Him whom he called upon before, and he attributes to Allāh equals to mislead [people] from His way. Say, "Enjoy your disbelief for a little; indeed, you are of the companions of the Fire."