Mahdia
Mahdia, on the Mediterranean coast of Tunisia, was founded in 921 by Abd Allah al-Mahdi (d. 934) as the first capital of the Fatimid (Ismaili Shi'i) caliphate, a fortified port chosen for its defensibility. It served as the Fatimid seat until the dynasty moved inland to al-Mansuriyya; the early Fatimid caliphs al-Qa'im and al-Mansur ruled from there.