Whenever Allah's Messenger (ﷺ) greeted somebody, he used to greet him three times, and if he spoke a sentence, he used to repeat it thrice.
Sahih al-Bukhari Book 79, Hadith 18