Shi'ism began with a reference made for the first time to the partisans of Ali (shi'ah-i 'Ali), the first leader of the Household of the Prophet, during the lifetime of the Prophet himself. The course of the first manifestation and the later growth of Islam during the twenty-three years of prophecy brought about many conditions which necessitated the appearance of a group such as the Shi'ites among the companions of the Prophet.
The Holy Prophet during the first days of his prophecy, when according to the text of the Quran he was commanded to invite his closer relatives to come to his religion, told them clearly that whoever would be the first to accept his invitation would become his successor and inheritor. Ali was the first to step forth and embrace Islam. The Prophet accepted Ali's submission to the faith and thus fulfilled his promise.
From the Shi'ite point of view it appears as unlikely that the leader of a movement, during the first days of his activity, should introduce to strangers one of his associates as his successor and deputy but not introduce him to his completely loyal and devout aides and friends. Nor does it appear likely that such a leader should accept someone as his deputy and successor and introduce him to others as such, but then throughout his life and religious call deprive his deputy of his duties as deputy, disregard the respect due to his position as successor, and refuse to make any distinctions between him and others.
The Prophet, according to many unquestioned and completely authenticated hadiths, both Sunni and Shi'ite, clearly asserted that Ali was preserved om error and sin in his actions and sayings. Whatever he said and did was in perfect conformity with the teachings of religion4 and he was the most knowledgeable of men in matters pertaining to the Islamic sciences and injunctions.
During the period of prophecy Ali performed valuable services and made remarkable sacrifices. When the infidels of Mecca decided to kill the Prophet and surrounded his house, the Holy Prophet decided to emigrate to Medina. He said to Ali, "Will you sleep in my bed at night so that they will think that lam asleep and will be secure from being pursued by them?" Ali accepted this dangerous assignment with open arms. This has been recounted in different histories and collections of hadith. (The emigration from Mecca to Medina marks the date of origin of the Islamic calendar, known as the hijrah.) Ali also served by fighting in the battles of Badr, Uhud, Khaybar, Khandaq, and Hunayn in which the victories achieved with his aid were such that if Ali had not been present the enemy would most likely have uprooted Islam and the Muslims, as is recounted in the usual histories, lives of the Prophet, and collections of hadith.
For Shi'ites, the central evidence of Ali's legitimacy as successor to the Prophet is the event of Ghadir Khumm when the Prophet chose Ali to the "general guardianship" (walayat-i 'ammah) of the people and made Ali, like himself, their "guardian" (wali). It is obvious that because of such distinctive services and recognition, because of Ali's special virtues which were acclaimed by all, and because of the great love the Prophet showed for him, some of the companions of the Prophet who knew Ali well, and who were champions of virtue and truth, came to love him. They assembled around Ali and followed him to such an extent that many others began to consider their love for him excessive and a few perhaps also became jealous of him. Besides all these elements, we see in many sayings of the Prophet reference to the "shi'ah of Ali" and the "shi'ah of the Household of the Prophet."