Jabir told of hearing God’s messenger say, “When you hear the barking of dogs and the braying of asses at night seek refuge in God from the accursed devil, for they see what you do not see. Do not go out much when there are few people about, for God who is great and glorious scatters abroad such of His creatures as He wishes at night* Shut the doors, making mention of God's name, for the devil does not open a door which has been shut accompanied by mention of God’s name. Cover up jars, invert vessels and tie up buckets.”
Abu Musa said that when a house in Medina was burned down during the night over its inhabitants and the Prophet was told, he said, “This fire is just an enemy to you, so when you go to sleep extinguish it.”
Ibn ‘Abbas told that when a mouse came dragging a wick and dropped it in front of God’s messenger on the mat on which he was sitting with the result th at it burned a hole in it about the size of dirham, he said, “When you go to sleep extinguish your lamps, for the devil guides a creature like this to do thus and sets you on fire.”