Ali was the first Muslim, and the first to pray, accepting Islam at the age of 10.
Tarikh al-Tabari, Vol. 6, Page 83
Narrated Mujahid b. Jabr Abu al-Hajjaj:

A mark of God's favor to 'Ali b. Abi Talib and his beneficence and benevolence towards him was the following. When Quraysh were afflicted by a severe drought, the Messenger of God, seeing that Abu Talib had many dependents, said to his uncle al-'Abbas, you brother Abu Talib has many dependents, and you see how people are suffering from this drought. Come with me and let us lighten the burden of his dependents. I will take one of his sons and you take one, and we will look after them for him." Al-'Abbas agreed, and they went to Abu Talib and said, "We wish to lighten the burden of your dependents until the hardship from which the people are suffering lifts."

 

Abu Talib said to them, "As long as you leave me 'Aqil, do as you wish." The Messenger of God took 'Ali and made him a member of his household, and al-Abbas did likewise with Ja'far. 'Ali b. Abi Talib continued to live with the Messenger of God until the latter became a prophet, and then followed him, believed in him, and accepted the truth of his message. Ja'far remained with al-'Abbas until he (Ja'far) professed Islam and became financially independent of him.

Book  : Tarikh at-Tabari
Author  : Muhammad ibn Jarir al-Tabari (224 AH - 310 AH)
English reference  : Vol. 6, Page 83
Arabic reference  : 
Narrated by: Ibn Humayd, from Salamah, from Muhammad b. Ishaq, from 'Abdallah b. Abi Najih, from Mujahid b. Jabr Abu al-Hajjaj.