The Messenger of Allah ﷺ, whenever he returned from a military expedition, Hajj, or Umrah, would begin by saying "Allahu Akbar" three times, then say, "There is no god but Allah alone, with no partner. To Him belongs the dominion and to Him belongs all praise, and He has power over all things. We return, repenting, worshipping, prostrating, praising our Lord. Allah has fulfilled His promise, granted victory to His servant, and defeated the confederates alone."
أن رسول الله ﷺ كان إذا قفل من الغزو أو الحج أو العمرة يبدأ فيكبر ثلاث مرار، ثم يقول: لا إله إلا الله وحده لا شريك له، له الملك وله الحمد، وهو على كل شيء قدير، آيبون عابدون، ساجدون، لربنا حامدون، صدق الله وعده، ونصر عبده، وهزم الأحزاب وحده.
Bukhari narrated it in "Al-Maghazi" (4116) and Muslim in "Al-Hajj" (1344:428), both through Nafi from Abdullah bin Umar, who said, so he mentioned it.