Padeshah Ali Mirza Safavi succeeded his father Haydar Safavi as leader of the Safaviyya, a Twelver Shi'i militant religious order, in 1488. He was killed in 1494 by order of the Ak Koyunlu leader, Roustam, who viewed his former ally as a growing threat. Ali Mirza's father and grandfather had married into the Ak Koyunlu dynasty: his mother was Alam-Shah Begum, daughter of the Ak Koyunlu leader Uzun Hasan.
Before he died, Ali Mirza designated his younger brother Ismail I as leader of the Safaviyya. Ismail then went into hiding, but reappeared in 1499 at 12 years of age to begin his military campaign of conquest.