The Prophet ﷺ said, "Allah extends His hand by night so that the one who sinned by day may repent, and He extends His hand by day so that the one who sinned by night may repent, until the sun rises from its place of setting."
عن النبي ﷺ قال: إن الله عز وجل يبسط يده بالليل ليتوب مسيء النهار، ويبسط يده بالنهار ليتوب مسيء الليل، حتى تطلع الشمس من مغربها.
Muslim narrated it in the book of Repentance (2759), from Muhammad bin Muthanna, who said, Muhammad bin Jafar told us, Shuba told us, from Amr bin Mura, who said, I heard Abu Ubayda narrating from Abu Musa, who said, then he mentioned it.