Ali ibn Abi Talib was the cousin and son-in-law of the Islamic prophet Muhammad, and was the fourth Rashidun caliph who ruled from 656 CE to 661, as well as the first Shia imam.