The Prophet (صلى الله عليه وسلم) said “The most superior way of asking for forgiveness from Allah is: ‘Allahumma anta Rabbi la ilaha illa anta, Khalaqtani wa ana `Abduka, wa ana `ala `ahdika wa wa`dika mastata`tu, A`udhu bika min Sharri ma sana`tu, abu’u Laka bini`matika `alaiya, wa abu’u laka bidhanbi faghfir lee fa innahu la yaghfiru adhdhunuba illa anta.” The Prophet (صلى الله عليه وسلم) added. “If somebody recites it during the day with firm faith in it, and dies on the same day before the evening, he will be from the people of Paradise; and if somebody recites it at night with firm faith in it, and dies before the morning, he will be from the people of Paradise.”
Reference: Sahih al-Bukari 6306
The dua (in Arabic):
O Allah! You are my Lord! None has the right to be worshiped but You. You created me and I am Your slave, and I am faithful to my covenant and my promise as much as I can. I seek refuge with You from all the evil I have done. I acknowledge before You all the blessings You have bestowed upon me, and I confess to You all my sins. So I entreat You to forgive my sins, for nobody can forgive sins except You.