The Hadith of Badʾ Al-Daʿwa (lit. ‘Beginning of the Preaching’), which is related to the beginning of the Prophet’s (PBUH) mission, is well-known to traditionalists, historians and Quranic commentators.
When God ordered the Prophet (PBUH) to call his close relatives to Islam –
“Warn the nearest of your kinsfolk” (Quran 26:214)
– he told Ali (AS) to prepare some food for the guests. After the leaders of the Banu Abd Al-Muttalib tribe had finished eating, the Prophet(PBUH) began to address them.
He said:
“The guide never lies. I swear by God, who is one and only, that I am God’s Prophet to you and all the people. You will die just as you sleep and you will be resurrected just as you wake up, and you will be judged for all you do. Then there will be everlasting paradise and eternal damnation. O’ Sons of Abd Al-Muttalib! By God, I know of no youth among Arabs who can offer something more valuable to people than what I offer to you. I advise you to believe in God, and whoever helps me in this will be my brother, my legatee and my successor among you.”
The Prophet (PBUH) repeated his call to Islam three times, and it was Ali (AS) who answered every time, “God’s Prophet, I am ready to help you in your mission.”
No one else responded. At this point, the Prophet (PBUH) said:
“I hereby declare that Ali is my brother, my legatee and my successor among you. So hearken to him and obey!” (Ibn Ḥanbal 1/111; Ṭabarī, 2/62; Ibn Athīr, 2/40).”
In this way, the Prophet (PBUH) declared Imam Ali (AS) his successor on the very day he declared his mission to his people.
Source: en.shafaqna.com