There is a Hadith in Sahih Bukhari, Sahih Muslim, Sunan Abu Dawood, Sunan Nasai, Jame Tirmidhi, Sunan Ibn Majah, etc.:
عَنْ أَبِي هُرَيْرَةَ أَنَّ رَسُولَ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ قَالَ مَنْ قَامَ رَمَضَانَ إِيمَانًا وَاحْتِسَابًا غُفِرَ لَهُ مَا تَقَدَّمَ مِنْ ذَنْبِه-ِ
Translation: It has been narrated on the authority of Hadhrat Abu Hurairah (May Allah be well pleased with him) that the Holy Prophet (Sallallahu alaihi wa sallam) said: Whoever stands in Salaat in the nights of Ramadhan in a state of Iman and sincerity (Ikhlas), all his (or her) past sins are forgiven.