It is narrated from Sayyiduna Salamah bin al-Akwa' (may Allah be pleased with him) that on the night before the morning of Khaybar, the Messenger of Allah (peace and blessings be upon him) said: "Tomorrow I will give this banner to a man whom Allah and His Messenger love; Allah will grant victory at his hands." And it turned out to be Sayyiduna Ali bin Abi Talib (may Allah be pleased with him). So the Messenger of Allah (peace and blessings be upon him) gave him the banner, and Allah granted victory at his hands.
Hadith Referenceالمعجم الكبير للطبراني / باب السين / 6260