Alid dynasties of northern Iran orAlavids (Persian:علویان طبرستان). In the 9th–10th centuries, the northernIranian regions ofTabaristan,Daylam andGilan, sandwiched between theCaspian Sea and theAlborz range, came under the rule of a number ofArabAlid dynasties, espousing theZaydi branch ofShia Islam.
The first and most powerful Zaydi emirate was established inTabaristan in 864 and lasted until 928. It was interrupted bySamanid occupation in 900, but restored in 914 by another Alid branch.
The second period of the Alid emirate was plagued by internal dissensions and power struggles between the two branches, and ended in the second conquest of the region by the Samanids in 928. Subsequently, some of the soldiers and generals of the Alavids joined the Samanids, among themMardavij, founder of theZiyarid dynasty, and the three sons of Buya (Ali, Hassan and Ahmad), founders of theBuyid dynasty.
Local Zaydi rulers survived in Daylam and Gilan until the 16th century.
Hasan ibn Zayd, adopted theregnal nameal-Da'i ila'l-Haqq (864–884). He was forced to abandon Tabaristan briefly forDaylam in 869 and 874 due to invasions
Muhammad ibn Zayd, also adopted the regnal nameal-Da'i ila'l-Haqq (884–900). Rule in Tabaristan proper was usurped by Abu'l-Husayn Ahmad ibn Muhammad for a few months as Muhammad was in Gurgan at the time of Hasan's death. Tabaristan was overrun briefly byRafi ibn Harthama in 891–893, and in 900 Muhammad tried to conquer Khurasan, but was defeated and killed by the Samanids. The Samanids captured Tabaristan, and the Alavids fled to Daylam in exile (900-913).
Hasan ibn Ali al-Utrush, adopted the regnal nameal-Nasir li'l-Haqq (914–917). AHusaynid fromMedina, he converted theGilites and Daylamites to the Zaydi doctrine, recovered Tabaristan.
Abu Muhammad Hasan ibn Qasim, also adopted the regnal nameal-Da'i ila'l-haq (917–919, 919–923, 927–928). A Hasanid, he was the commander of the army under al-Utrush and named by the latter as his heir. His rule was challenged by al-Utrush's sons and their numerous supporters (the "Nasiris"), who seized power twice, briefly in 919 and again in 923. Regained the throne with the help ofMakan ibn Kaki, and ruled until he was killed in battle withAsfar ibn Shiruya.
Abu 'l-Husayn Ahmad ibn Hasan, surnamedNasir (919, 923). Reigned jointly with his brother in 919, thereafter reconciled himself with Abu Muhammad Hasan al-Da'i until 923, when he reigned briefly until his death.
Abu 'l-Qasim Ja'far ibn Hasan, surnamedNasir (919, 923–925). Reigned jointly with his brother in 919 and from 923 until his death.
Abu Ali Muhammad ibn Abu 'l-Husayn Ahmad, surnamedNasir (925–927). Son of Ahmad ibn Hasan, he was chosen as emir after Ja'far died. Deposed briefly by Makan ibn Kaki, who installed Isma'il ibn Ja'far as a puppet ruler, regained the throne with the aid of Asfar ibn Shiruya.
Abu Ja'far Husayn ibn Abu 'l-Husayn Ahmad, surnamedNasir (927). Brother of Abu Ali Muhammad, he was deposed by Makan ibn Kaki, who brought back Abu Muhammad Hasan al-Da'i. Installed once more as imam briefly by Asfar ibn Shiruya underSamanid suzerainty, but later removed to the Samanid court atBukhara. Tried to recover Tabaristan in 931 with the help ofMardavij, but failed.