Warrad, the freed slave of Mughira b. Shu'ba, reported: Mughira b. Shu'ba wrote to Mu'awiya (it was Warrad who wrote this letter for him, i. e. Mughira): I heard the Messenger of Allah ﷺ saying:" When the salutation is pronounced". and the rest of the hadith is the same except this that he made no mention of:" He is Potent over everything".
By greeting each other in this way it shows our love for one another and our commitment to living peacefully together in harmony. We can also use this phrase as an expression of hope for the future; by saying “As-salamu alaykum” we are wishing each other peace now and into the future too!