Surah An-Nur, ayah 27

24:27

يَٰٓأَيُّهَا ٱلَّذِينَ ءَامَنُواْ لَا تَدۡخُلُواْ بُيُوتًا غَيۡرَ بُيُوتِكُمۡ حَتَّىٰ تَسۡتَأۡنِسُواْ وَتُسَلِّمُواْ عَلَىٰٓ أَهۡلِهَاۚ ذَٰلِكُمۡ خَيۡرٞ لَّكُمۡ لَعَلَّكُمۡ تَذَكَّرُونَ ٢٧

Yā'ayyuhal-ladhīna āmanū lā tadkhulū buyūtan ghayra buyūtikum hattā tasta'nisū watusallimū 'alā ahlihā dhālikum khayrul lakum la'allakum tadhakkarūn

O you who have believed, do not enter houses other than your own houses until you ascertain welcome and greet985 their inhabitants. That is best for you; perhaps you will be reminded [i.e., advised].

Footnotes

985 By the words "As-salāmu ʿalaykum" ("Peace be upon you").