[Machine] Suhaib, the companion of the Prophet ﷺ , reported that the Prophet ﷺ said whenever he wanted to enter a town, he would say upon seeing it, "O Allah, Lord of the seven heavens and what they overshadow, Lord of the seven earths and what they contain, Lord of the devils and what they lead astray, Lord of the winds and what they scatter. We ask You for the goodness of this town and the goodness of its people, and seek refuge in You from its evil and the evil of its people and the evil within it."
أَنَّ صُهَيْبًا صَاحِبَ النَّبِيِّ ﷺ حَدَّثَهُ أَنَّ النَّبِيَّ ﷺ لَمْ يَرَ قَرْيَةً يُرِيدُ دُخُولَهَا إِلَّا قَالَ حِينَ يَرَاهَا «اللَّهُمَّ رَبَّ السَّمَاوَاتِ السَّبْعِ وَمَا أَظْلَلْنَ وَرَبَّ الْأَرَضِينَ السَّبْعِ وَمَا أَقْلَلْنَ وَرَبَّ الشَّيَاطِينِ وَمَا أَضْلَلْنَ وَرَبَّ الرِّيَاحِ وَمَا ذَرَيْنَ فَإِنَّا نَسْأَلُكَ خَيْرَ هَذِهِ الْقَرْيَةِ وَخَيْرَ أَهْلِهَا وَنَعُوذُ بِكَ مِنْ شَرِّهَا وَشَرِّ أَهْلِهَا وَشَرِّ مَا فِيهَا»