The Prophet ﷺ said, "Do not leave fire burning in your homes when you go to sleep."
عن النبي ﷺ قال: لا تتركوا النار في بيوتكم حين تنامون.
Bukhari narrated it in the Book of Seeking Permission (6293), and Muslim in the Book of Drinks (2015), both of them through the route of Sufyan bin Uyayna, from Zuhri, from Salim, from his father, who mentioned it.