It is narrated from Sayyiduna Abdullah bin Salam (may Allah be pleased with him), who said: I do not tell you anything except on the authority of a revealed Book or a sent Prophet: No soul repents a day before the illness in which it is to die except that Allah accepts its repentance, (and this will continue) until the sun rises from the west.
Hadith Referenceالمعجم الكبير للطبراني / باب العين / 13987