On the authority of Khawla bint Hakim (may Allah be pleased with her), who said: I heard the Messenger of Allah ﷺ saying: “Whoever alights at a lodging place and then says: ‘I seek refuge in the perfect words of Allah from the evil of what He has created,’ nothing will harm him until he departs from that lodging place of his.” Narrated by Muslim.
Hadith983
﵄، - ﷺ - .
And on the authority of Ibn ʻUmar (may Allah be pleased with them both), who said: Whenever the Messenger of Allah ﷺ travelled and night came on, he would say: “O earth, my Lord and your Lord is Allah. I seek refuge in Allah from your evil, and the evil of what is in you, and the evil of what was created in you, and the evil of what crawls upon you. And I seek refuge in You from the evil of a lion and a black one (al-aswad), and from the snake and the scorpion, and from the dweller of the land, and from a begetter and what it begot.” Narrated by Abu Dawud. And “al-aswad” means: the figure (a person). Al-Khattabi said: and “the dweller of the land” are the jinn who are the inhabitants of the earth. He said: and the “land” of the earth is whatever serves as a shelter for animals, even if there is no building or dwellings upon it. He said: and it is possible that what is intended by “the begetter” is Iblis, and by “what it begot,” the devils.