then ruler of Yemen. The first Zaidi imam, Yahya ibn al-Husayn, arrived to Yemen in 893. He was the founder of the Zaidi imamate in 897. He was a religious cleric and judge who was invited to come to Saada from Medina to arbitrate tribal disputes. Imam Yahya persuaded local tribesmen to follow his teachings. The sect slowly spread across the highlands, as the tribes of Hashid and Bakil, later known as the twin wings of the imamate, accepted his authority. Yahya established his influence in Saada and Najran; he also tried to capture Sana'a from the Yufirids in 901, but he failed miserably. In 904, the newly established Isma'ili followers invaded Sana'a. The Yufirid emir As'ad ibn Ibrahim retreated to Al-Jawf, and between 904 and 913, Sana'a was conquered no less than 20 times by Isma'ilis and Yufirids. As'ad ibn Ibrahim regained Sana'a in 915. The country was in turmoil as Sana'a became a battlefield for the three dynasties as well as independent tribes. The Yufirid emir Abdullah ibn Qahtan attacked and burned Zabid in 989, severely weakening the Ziyadid dynasty. The Ziyadid monarchs lost effective power after 989, or even earlier than that. Meanwhile, a succession of slaves held power in Zabid and continued to govern in the name of their masters eventually establishing their own dynasty around 1022 or 1050 according to different sources. Although they were recognized by the Abbasid Caliphate in Baghdad, they ruled no more than Zabid and four districts to its north. The rise of the Ismaili Shia Sulayhid dynasty in the Yemeni highlands reduced their history to a series of intrigues. Sulayhid Dynasty The Sulayhid dynasty was founded in the northern highlands around 1040. At the time, Yemen was ruled by different local dynasties. In 1060, Ali ibn Mohammed Al-Sulayhi conquered Zabid and killed its ruler Al-Najah, founder of the Najahid dynasty, whose sons were forced to flee to Dahlak. Hadramawt fell into Sulayhid hands after their capture of Aden in 1062. By 1063, Ali had subjugated Greater Yemen. He then marched toward Hejaz and occupied Makkah. Ali was married to Asma bint Shihab, who governed Yemen with her husband. The Khutba during Friday prayers was proclaimed in her husband's and her name. No other Arab woman had this honor since the advent of Islam. Ali al-Sulayhi was killed by Najah's sons on his way to Mecca in 1084. His son Ahmad