The Prophet ﷺ said: When a man commits fornication, faith departs from him and there is something like a canvas roof over his head; and when he quits that action, faith returns to him.
قَالَ رَسُولُ اللَّهِ ﷺ إِذَا زَنَى الرَّجُلُ خَرَجَ مِنْهُ الإِيمَانُ كَانَ عَلَيْهِ كَالظُّلَّةِ فَإِذَا انْقَطَعَ رَجَعَ إِلَيْهِ الإِيمَانُ