Abu Musa Al-Ash'ari (May Allah be pleased with him) reported:
The Messenger of Allah (ﷺ) said, "Permission is to be sought thrice. If it is accorded, you may enter; otherwise, go back."[Al- Bukhari and Muslim]. (IT)
App reference (IT): Book 6, Hadith 26 (IT)
Arabic/English book reference (IT): Book 6, Hadith 870 (IT)