Fatimid Caliphate

The Fatimid Caliphate or Fatimid Empire (ٱلْخِلَافَة ٱلْفَاطِمِيَّة) was a caliphate extant from the tenth to the twelfth centuries CE under the rule of the Fatimids, an Isma'ili Shia dynasty. Spanning a large area of North Africa and West Asia, it ranged from the western Mediterranean in the west to the Red Sea in the east. The Fatimids trace their ancestry to the Islamic prophet Muhammad's daughter Fatima and her husband Ali, the first Shia imam. The Fatimids were acknowledged as the rightful imams by different Isma‘ili communities as well as by denominations in many other Muslim lands and adjacent regions. Originating during the Abbasid Caliphate, the Fatimids initially conquered Ifriqiya (roughly present-day Tunisia). They extended their rule across the Mediterranean coast and ultimately made Egypt the center of the caliphate. At its height, the caliphate included—in addition to Egypt—varying areas of the Maghreb, Sicily, the Levant, and the Hejaz.

Between 902 and 909, the foundation of the Fatimid state was realized under the leadership of da'i (missionary) Abu Abdallah, whose conquest of Aghlabid Ifriqiya with the help of Kutama forces paved the way for the establishment of the Caliphate. After the conquest, Abdallah al-Mahdi Billah was retrieved from Sijilmasa and then accepted as the Imam of the movement, becoming the first Caliph and founder of the dynasty in 909. In 921, the city of al-Mahdiyya was established as the capital. In 948, they shifted their capital to al-Mansuriyya, near Kairouan. In 969, during the reign of al-Mu'izz, they conquered Egypt, and in 973, the caliphate was moved to the newly founded Fatimid capital of Cairo. Egypt became the political, cultural, and religious centre of the empire and it developed a new and "indigenous Arabic culture". After its initial conquests, the caliphate often allowed a degree of religious tolerance towards non-Shia sects of Islam, as well as to Jews and Christians. However, its leaders made little headway in persuading the Egyptian population to adopt its religious beliefs.

After the reigns of al-'Aziz and al-Hakim, the long reign of al-Mustansir entrenched a regime in which the caliph remained aloof from state affairs and viziers took on greater importance. Political and ethnic factionalism within the army led to a civil war in the 1060s, which threatened the empire's survival. After a period of revival during the tenure of the vizier Badr al-Jamali, the Fatimid caliphate declined rapidly during the late eleventh and twelfth centuries. In addition to internal difficulties, the caliphate was weakened by the encroachment of the Seljuk Turks into Syria in the 1070s and the arrival of the Crusaders in the Levant in 1097. In 1171, Saladin abolished the dynasty's rule and founded the Ayyubid dynasty, which incorporated Egypt back into the nominal sphere of authority of the Abbasid Caliphate.

Name
The Fatimid dynasty claimed descent from Fatimah, the daughter of the Islamic prophet Muhammad. The dynasty legitimized its claim through descent from Muhammad by way of his daughter and her husband Ali, the first Shī'a Imām, hence the dynasty's name, fāṭimiyy (فَاطِمِيّ), the Arabic relative adjective for "Fāṭima".

Emphasizing its Alid descent, the dynasty named itself simply the 'Alid dynasty', but many hostile Sunni sources only refer to them as the Ubaydids , after the diminutive form Ubayd Allah for the name of the first Fatimid caliph.

Origins
The Fatimid dynasty came to power as the leaders of Isma'ilism, a revolutionary Shi'a movement "which was at the same time political and religious, philosophical and social,” and which originally proclaimed nothing less than the arrival of an Islamic messiah. The origins of that movement and of the dynasty itself, are obscure prior to the late ninth century.

The Fatimid rulers were Arab in origin, starting with its founder, the Isma'ili Shia caliph Abdallah al-Mahdi Billah. The caliphate's establishment was accomplished by Kutama Berbers from Little Kabylia, who converted to the Fatimid cause early and made up its original military forces.

Early Shi'ism and the roots of Isma'ilism
The Shi'a opposed the Umayyad and Abbasid caliphates, whom they considered usurpers. Instead, they believed in the exclusive right of the descendants of Ali through Muhammad's daughter Fatima, to lead the Muslim community. This manifested itself in a line of imams, descendants of Ali via al-Husayn, whom their followers considered as the true representatives of God on earth. At the same time, there was a widespread messianic tradition in Islam concerning the appearance of a ("the Rightly Guided One") or  ("He Who Arises"), who would restore true Islamic government and justice and usher in the end times. This figure was widely expected – not just among the Shi'a – to be a descendant of Ali. Among Shi'a, however, this belief became a core tenet of their faith, and was applied to several Shi'a leaders who were killed or died; their followers believed that they had gone into "occultation" and would return (or be resurrected) at the appointed time.

These traditions manifested themselves in the succession of the sixth imam, Ja'far al-Sadiq. Al-Sadiq had appointed his son Isma'il ibn Ja'far as his successor, but Isma'il died before his father, and when al-Sadiq himself died in 765, the succession was left open. Most of his followers followed al-Sadiq's son Musa al-Kazim down to a twelfth and final imam who supposedly went into occultation in 874 and would one day return as the. This branch is hence known as the "Twelvers". Others followed other sons, or even refused to believe that al-Sadiq had died, and expected his return as the. Another branch believed that Ja'far was followed by a seventh imam, who had gone into occultation and would one day return; hence this party is known as the "Seveners". The exact identity of that seventh imam was disputed, but by the late ninth century had commonly been identified with Muhammad, son of Isma'il and grandson of al-Sadiq. From Muhammad's father, Isma'il, the sect, which gave rise to the Fatimids, receives its name of "Isma'ili". Due to the harsh Abbasid persecution of the Alids, the Ismaili Imams went into hiding and neither Isma'il's nor Muhammad's lives are well known, and after Muhammad's death during the reign of Harun al-Rashid ((r. 786 – 809)), the history of the early Isma'ili movement becomes obscure.

The secret network
While the awaited Muhammad ibn Isma'il remained hidden, however, he would need to be represented by agents, who would gather the faithful, spread the word (, "invitation, calling"), and prepare his return. The head of this secret network was the living proof of the imam's existence, or "seal". It is this role that the ancestors of the Fatimids are first documented. The first known ḥujja was a certain Abdallah al-Akbar ("Abdallah the Elder"), a wealthy merchant from Khuzestan, who established himself at the small town of Salamiya on the western edge of the Syrian Desert. Salamiya became the centre of the Isma'ili, with Abdallah al-Akbar being succeeded by his son and grandson as the secret "grand masters" of the movement.

In the last third of the ninth century, the Isma'ili spread widely, profiting from the collapse of Abbasid power in the Anarchy at Samarra and the subsequent Zanj Revolt, as well as from dissatisfaction among Twelver adherents with the political quietism of their leadership and the recent disappearance of the twelfth imam. Missionaries (s) such as Hamdan Qarmat and Ibn Hawshab spread the network of agents to the area round Kufa in the late 870s, and from there to Yemen (882) and thence India (884), Bahrayn (899), Persia, and the Maghreb (893).

The Qarmatian schism and its aftermath
In 899, Abdallah al-Akbar's great-grandson, Abdallah, became the new head of the movement, and introduced a radical change in the doctrine: no longer was he and his forebears merely the stewards for Muhammad ibn Isma'il, but they were declared to be the rightful imams, and Abdallah himself was the awaited. Various genealogies were later put forth by the Fatimids to justify this claim by proving their descent from Isma'il ibn Ja'far, but even in pro-Isma'ili sources, the succession and names of imams differ, while Sunni and Twelver sources of course reject any Fatimid descent from the Alids altogether and consider them impostors. Abdallah's claim caused a rift in the Isma'ili movement, as Hamdan Qarmat and other leaders denounced this change and held onto the original doctrine, becoming known as the "Qarmatians", while other communities remained loyal to Salamiya. Shortly after, in 902–903, pro-Fatimid loyalists began a great uprising in Syria. The large-scale Abbasid reaction it precipitated and the attention it brought on him, forced Abdallah to abandon Salamiya for Palestine, Egypt, and finally for the Maghreb, where the Abu Abdallah al-Shi'i had made great headway in converting the Kutama Berbers to the Isma'ili cause. Unable to join his directly, Abdallah instead settled at Sijilmasa sometime between 904 and 905.

Establishment of the Isma'ili State
Prior to the Fatimid rise to power, a large part of the Maghreb including Ifriqiya was under the control of the Aghlabids, an Arab dynasty who ruled nominally on behalf the Abbasids but were de facto independent. In 893 the Abu Abdallah al-Shi'i first settled among the Banu Saktan tribe (part of the larger Kutama tribe) in Ikjan, near the city of Mila (in northwestern Algeria today). However, due to hostility from the local Aghlabid authorities and other Kutuma tribes, he was forced to leave Ikjan and sought the protection of another Kutama tribe, the Banu Ghashman, in Tazrut (two miles southwest of Mila). From there, he began to build support for a new movement. Shortly after, the hostile Kutama tribes and the Arab lords of the nearby cities (Mila, Setif, and Bilizma) allied together to march against him, but he was able to move quickly and muster enough support from friendly Kutama to defeat them one by one before they were able to unite. This first victory brought Abu Abdallah and his Kutama troops valuable loot and attracted more support to the 's cause. Over the next two years Abu Abdallah was able to win over most of the Kutama tribes in the region through either persuasion or coercion. This left much of the countryside under his control, while the major cities remained under Aghlabid control. He established an Isma'ili theocratic state based in Tazrut, operating in a way similar to previous Isma'ili missionary networks in Mesopotamia but adapted to local Kutama tribal structures. He adopted the role of a traditional Islamic ruler at the head of this organization while remaining in frequent contact with Abdallah. He continued to preach to his followers, known as the Awliya' Allah ('Friends of God'), and to initiate them into Isma'ili doctrine.

Conquest of Aghlabid Ifriqiya


In 902, while the Aghlabid emir Ibrahim II was away on campaign in Sicily, Abu Abdallah struck the first significant blow against Aghlabid authority in North Africa by attacking and capturing the city of Mila for the first time. This news triggered a serious response from the Aghlabids, who sent a punitive expedition of 12,000 men from Tunis in October of the same year. Abu Abdallah's forces were unable to resist this counterattack and after two defeats they evacuated Tazrut (which was largely unfortified) and fled to Ikjan, leaving Mila to be retaken. Ikjan became the new center of the Fatimid movement and the reestablished his network of missionaries and spies.

Ibrahim II died in October 902 while in southern Italy and was succeeded by Abdallah II. In early 903 Abdallah II set out on another expedition to destroy Ikjan and the Kutama rebels, but he ended the expedition prematurely due to troubles at home arising from disputes over his succession. On 27 July 903 he was assassinated and his son Ziyadat Allah III took power in Tunis. These internal Aghlabid troubles gave Abu Abdallah the opportunity to recapture Mila and then go on to capture Setif, another fortified city, by October or November 904. In 905 the Aghlabids sent a third expedition to try and subdue the Kutama. They based themselves in Constantine and in the fall of 905, after receiving further reinforcements, set out to march against Abu Abdallah. However, they were surprised by Kutama forces on the first day of their march, which caused a panic and scattered their army. The Aghlabid general fled and the Kutama captured a large booty. Another Aghlabid military expedition organized the next year (906) failed when the soldiers mutinied. Around the same time or soon after, Abu Abdallah's forces besieged and captured the fortified cities of Tubna and Bilizma. The capture of Tubna was significant as it was the first major commercial center to come under Abu Abdallah's control.

Meanwhile, Ziyadat Allah III moved his court from Tunis to Raqqada, the palace-city near Kairouan, in response to the growing threat. He fortified Raqqada in 907. In early 907 another Aghlabid army marched eastwards again against Abu Abdallah, accompanied by Berber reinforcements from the Aurès Mountains. They were again scattered by Kutama cavalry and retreated to Baghaya, the most fortified town on the old southern Roman road between Ifriqiya and the central Maghreb. The fortress, however, fell to the Kutama without a siege when local notables arranged to have the gates opened to them in May or June 907. This opened a hole in the wider defensive system of Ifriqiya and created panic in Raqqada. Ziyadat Allah III stepped up anti-Fatimid propaganda, recruited volunteers, and took measures to defend the weakly-fortified city of Kairouan. He spent the winter of 907–908 with his army in al-Aribus (Roman-era Laribus, between present-day El Kef and Maktar), expecting an attack from the north. However, Abu Abdallah's forces had been unable to capture the northerly city of Constantine and therefore they instead attacked along the southern road from Baghaya in early 908 and captured Maydara (present-day Haïdra). An indecisive battle subsequently occurred between the Aghalabid and Kutama armies near Dar Madyan (probably a site between Sbeitla and Kasserine), with neither side gaining the upper hand. During the winter of 908–909 Abu Abdallah campaigned in the region around Chott el-Jerid, capturing the towns of Tuzur (Tozeur), Nafta, and Qafsa (Gafsa) and taking control of the region. The Aghlabids responded by besieging Baghaya soon afterward in the same winter, but they were quickly repelled.

On 25 February 909, Abu Abdallah set out from Ikjan with an army of 200,000 men for a final invasion of Kairouan. The remaining Aghlabid army, led by an Aghlabid prince named Ibrahim Ibn Abi al-Aghlab, met them near al-Aribus on 18 March. The battle lasted until the afternoon, when a contingent of Kutama horsemen managed to outflank the Aghlabid army and finally caused a rout. When news of the defeat reached Raqqada, Ziyadat Allah III packed his valuable treasures and fled towards Egypt. The population of Kairouan looted the abandoned palaces of Raqqada and resisted Ibn Abi al-Aghlab's calls to organise a last-ditch resistance. Upon hearing of the looting, Abu Abdallah sent an advance force of Kutama horsemen who secured Raqqada on 24 March. On 25 March 909 (Saturday, 1 Rajab 296), Abu Abdallah himself entered Raqqada and took up residence here.

Establishment of the Caliphate
Upon assuming power in Raqqada, Abu Abdallah inherited much of the Aghlabid state's apparatus and allowed its former officials to continue working for the new regime. He established a new, Isma'ili Shi'a regime on behalf of his absent, and for the moment unnamed, master. He then led his army west to Sijilmasa, whence he led Abdallah in triumph to Raqqada, which he entered on 15 January 910. There Abdallah publicly proclaimed himself as caliph with the regnal name of, and presented his son and heir, with the regnal name of al-Qa'im. Al-Mahdi quickly fell out with Abu Abdallah: not only was the over-powerful, but he demanded proof that the new caliph was the true. The elimination of Abu Abdallah al-Shi'i and his brother led to an uprising among the Kutama, led by a child-, which was suppressed. At the same time, al-Mahdi repudiated the millenarian hopes of his followers and curtailed their antinomian tendencies.

The new regime regarded its presence in Ifriqiya as only temporary: the real target was Baghdad, the capital of the Fatimids' Abbasid rivals. The ambition to carry the revolution eastward had to be postponed after the failure of two successive invasions of Egypt, led by al-Qa'im, in 914–915 and 919–921. In addition, the Fatimid regime was as yet unstable. The local population were mostly adherents of Maliki Sunnism and various Kharijite sects such as Ibadism, so that the real power base of Fatimids in Ifriqiya was quite narrow, resting on the Kutama soldiery, later extended by the Sanhaja Berber tribes as well. The historian Heinz Halm describes the early Fatimid state as being, in essence, "a hegemony of the Kutama and Sanhaja Berbers over the eastern and central Maghrib".

In 912, al-Mahdi began looking for the site of a new capital along the Mediterranean shore. Construction of the new fortified palace city, al-Mahdiyya, began in 916. The new city was officially inaugurated on 20 February 921, though construction continued after this. The new capital was removed from the Sunni stronghold of Kairouan, allowing for the establishment of a secure base for the Caliph and his Kutama forces without raising further tensions with the local population.

The Fatimids also inherited the Aghlabid province of Sicily, which the Aghlabids had gradually conquered from the Byzantine Empire starting in 827. The conquest was generally completed when the last Christian stronghold, Taormina, was conquered by Ibrahim II in 902. However, some Christian or Byzantine resistance continued in some spots in the northeast of Sicily until 967, and the Byzantines still held territories in southern Italy, where the Aghlabids had also campaigned. This ongoing confrontation with the traditional foe of the Islamic world provided the Fatimids with a prime opportunity for propaganda, in a setting where geography gave them the advantage. Sicily itself proved troublesome, and only after a rebellion under Ibn Qurhub was subdued, was Fatimid authority on the island consolidated.

Consolidation and western rivalry
For a large part of the tenth century the Fatimids also engaged in a rivalry with the Umayyads of Cordoba – who ruled Al-Andalus and were hostile to the Fatimids' pretensions – in an effort to establish domination over the western Maghreb. In 911, Tahert, which had been briefly captured by Abu Abdallah al-Shi'i in 909, had to be retaken by the Fatimid general Masala ibn Habus of the Miknasa tribe. The first Fatimid expeditions to what is now northern Morocco occurred in 917 and 921 and were primarily aimed at the Principality of Nakur, which they subjugated on both occasions. Fez and Sijilmasa were also captured in 921. These two expeditions were led by Masala ibn Habus, who had been made governor of Tahert. Thereafter, the weakened Idrisids and various local Zenata and Sanhaja leaders acted as proxies whose formal allegiances oscillated between the Umayyads or the Fatimids depending on the circumstances. As a result of the political instability in the western Maghreb, effective Fatimid control did not extend much beyond the former territory of the Aghlabids. Masala's successor, Musa ibn Abi'l-Afiya, captured Fez from the Idrisids again, but in 932 defected to the Umayyads, taking the western Maghreb with him. The Umayyads gained the upper hand again in northern Morocco during the 950s, until the Fatimid general Jawhar, on behalf of Caliph Al-Mu'izz li-Din Allah, led another major expedition to Morocco in 958 and spent two years subjugating most of northern Morocco. He was accompanied by Ziri ibn Manad, the leader of the Zirids. Jawhar took Sijilmasa in September or October 958 and then, with the help of Ziri, his forces took Fez in November 959. He was unable, however, to dislodge the Umayyad garrisons in Sala, Sebta (present-day Ceuta) and Tangier, and this marked the only time that the Fatimid army was present at the Strait of Gibraltar. Jawhar and Ziri returned to al-Mansuriyya in 960. The subjugated parts of Morocco, including Fez and Sijilmasa, were left under the control of local vassals while most of the central Maghreb (Algeria), including Tahert, was given to Ziri ibn Manad to govern on the caliph's behalf.

All this warfare in the Maghreb and Sicily necessitated the maintenance of a strong army, and a capable fleet as well. Nevertheless, by the time of al-Mahdi's death in 934, the Fatimid Caliphate "had become a great power in the Mediterranean". The reign of the second Fatimid imam-caliph, al-Qa'im, was dominated by the Kharijite rebellion of Abu Yazid. Starting in 943/4 among the Zenata Berbers, the uprising spread through Ifriqiya, taking Kairouan and blockading al-Qa'im at al-Mahdiyya, which was besieged in January–September 945. Al-Qa'im died during the siege, but this was kept secret by his son and successor, Isma'il, until he had defeated Abu Yazid; he then announced his father's death and proclaimed himself imam and caliph as al-Mansur. While al-Mansur was campaigning to suppress the last remnants of the revolt, a new palace city was being constructed for him south of Kairouan. Construction began around 946 and it was only fully completed under al-Mansur's son and successor, al-Mu'izz. It was named al-Mansuriyya (also known as Sabra al-Mansuriyya) and became the new seat of the caliphate.

Conquest of Egypt and transfer of the Caliphate to Cairo
In 969 Jawhar launched a carefully-prepared and successful invasion of Egypt, which had been under the control of the Ikhshidids, another regional dynasty whose formal allegiance was to the Abbasids. Al-Mu'izz had given Jawhar specific instructions to carry out after the conquest, and one of his first actions was to found a new capital named al-Qāhira (Cairo) in 969. The name al-Qāhirah (القاهرة), meaning "the Vanquisher" or "the Conqueror", referenced the planet Mars, "The Subduer", rising in the sky at the time when the construction of the city started. The city was located several miles northeast of Fusṭāt, the older regional capital founded by the Arab conquerors in the seventh century.

Control of Egypt was secured with relative ease and soon afterward, in 970, Jawhar sent a force to invade Syria and remove the remaining Ikhshidids who had fled there from Egypt. This Fatimid force was led by a Kutama general named Ja'far ibn Falāḥ. This invasion was successful at first and many cities, including Damascus, were occupied that same year. Ja'far's next step was to attack the Byzantines, who had captured Antioch and subjugated Aleppo in 969 (around the same time as Jawhar was arriving in Egypt), but he was forced to call off the advance in order to face a new threat from the east. The Qarmatis of Bahrayn, responding to the appeal of the recently defeated leaders of Damascus, had organized a large coalition of Arab tribesmen to attack him. Ja'far chose to confront them in the desert in August 971, but his army was surrounded and defeated and Ja'far himself was killed. A month later the Qarmati imam Hasan al-A'ṣam led the army, with new reinforcements from Transjordan, into Egypt, seemingly without opposition. The Qarmatis spent time occupying the Nile Delta region, which gave Jawhar time to organize a defense of Fustat and Cairo. The Qarmati advance was halted just north of the city and eventually routed. A Kalbid relief force arriving by sea secured the expulsion of the Qarmatis from Egypt. Ramla, the capital of Palestine, was retaken by the Fatimids in May 972, but otherwise the progress in Syria had been lost.

Once Egypt was sufficiently pacified and the new capital was ready, Jawhar sent for al-Mu'izz in Ifriqiya. The caliph, his court, and his treasury, departed from al-Mansuriyya in fall 972, traveling by land but shadowed by the Fatimid navy sailing along the coast. After making triumphant stops in major cities along the way, the caliph arrived in Cairo on 10 June 973. Like other royal capitals before it, Cairo was constructed as an administrative and palatine city, housing the palaces of the caliph and the official state mosque, Al-Azhar Mosque. In 988 the mosque also became an academic institution that was central in the dissemination of Isma'ili teachings. Until the last years of the Fatimid Caliphate, the economic centre of Egypt remained Fustat, where most of the general population lived and traded.

Under the Fatimids, Egypt became the centre of an empire that included at its peak parts of North Africa, Sicily, the Levant (including Transjordan), the Red Sea coast of Africa, Tihamah, Hejaz, Yemen, with its most remote territorial reach being Multan (in modern-day Pakistan). Egypt flourished, and the Fatimids developed an extensive trade network both in the Mediterranean and in the Indian Ocean. Their trade and diplomatic ties, extending all the way to China under the Song Dynasty ((r. 960 – 1279)), eventually determined the economic course of Egypt during the High Middle Ages. The Fatimid focus on agriculture further increased their riches and allowed the dynasty and the Egyptians to flourish. The use of cash crops and the propagation of the flax trade allowed Fatimids to import other items from various parts of the world. The Fatimids built upon some of the bureaucratic foundations laid by the Ikhshidids and the old Abbasid imperial order. The office of the wazīr (vizier), which existed under the Ikhshidids, was soon revived under the Fatimids. The first to be appointed to this position was the Jewish convert Ya'qub ibn Killis, who was elevated to this office in 979 by al-Mu'izz's successor al-Aziz. The office of the vizier became progressively more important over the years, as the vizier became the intermediary between the caliph and the large bureaucratic state that he ruled.

Campaigns in Syria
In 975 the Byzantine emperor John Tzimisces retook most of Palestine and Syria, leaving only Tripoli in Fatimid control. He aimed to eventually capture Jerusalem, but he died in 976 on his way back to Constantinople, thus staving off the Byzantine threat to the Fatimids. Meanwhile, the Turkish ghulām (plural: ghilmān, meaning soldiers recruited as slaves) Aftakin, a Buyid refugee who had fled an unsuccessful rebellion in Baghdad with his own contingent of Turkish soldiers, became the protector of Damascus. He allied with the Qarmatis and with Arab Bedouin tribes in Syria and invaded Palestine in the spring of 977. Jawhar, once again called into action, repelled their invasion and besieged Damascus. However he suffered a rout during the winter and was forced to hold out in Ascalon against Aftakin. When his Kutama soldiers mutinied in April 978, Caliph al-Aziz himself led an army to relieve him. Instead of returning to Damascus, Aftakin and his Turkish ghilman joined the Fatimid army and became a useful instrument in the Syrian effort.

After Ibn Killis became vizier in 979, the Fatimids changed tactics. Ibn Killis was able to subjugate most of Palestine and southern Syria (the former Ikhshidid territories) by paying off the Qarmatis with an annual tribute and making alliances with local tribes and dynasties, such as the Jarrahids and the Banu Kilab. Following another failed attempt by a Kutama general, Salman, to take Damascus, the Turkish ghulām Bultakīn finally succeeded in occupying the city for the Fatimids in 983, demonstrating the value of this new force. Another ghulām, Bajkūr, who appointed governor of Damascus at this time. That same year he tried and failed to take Aleppo, but he was soon able to conquer Raqqa and Rahba in the Euphrates valley (present-day northeast Syria). Cairo eventually judged him to be a little too popular as governor of Damascus and he was forced to move to Raqqa while Munir, a eunuch in the caliph's household (like Jawhar before him), took direct control in Damascus on behalf of the caliph. Further north, Aleppo remained out of reach and under Hamdanid control.

The incorporation of the Turkish troops into the Fatimid army had long-term consequences. On the one hand, they were a necessary addition to the military in order for the Fatimids to compete militarily with other powers in the region. The Fatimids began to recruit ghilmān much as the Abbasids had done before them. They were soon joined by recruited Daylamis (footmen from the Buyid homeland in Iran). Black Africans from the Sudan (upper Nile valley) were also recruited afterward. In the short term the Kutama warriors remained the most important troops of the Caliph, but resentment and rivalry eventually grew between the different ethnic components of the army.

Bajkūr, based in Raqqa, made another unsuccessful attempt against Aleppo in 991 which resulted in his capture and execution. That same year, Ibn Killis died and Munir was accused of conducting treasonous correspondence with Baghdad. These difficulties triggered a strong response in Cairo. A major military campaign was prepared to impose Fatimid control over all of Syria. Along the way, Munir was arrested in Damascus and sent back to Cairo. Circumstances were favourable to the Fatimids as the Byzantine emperor Basil II was campaigning far away in the Balkans and the Hamdanid ruler Sa'd al-Dawla died in late 991. Manjūtakīn, the Turkish Fatimid commander, advanced methodically north along the Orontes valley. He took Homs and Hama in 992 and defeated a combined force from Hamdanid Aleppo and Byzantine-held Antioch. In 993 he took Shayzar and in 994 he began the siege of Aleppo. In May 995, however, Basil II unexpectedly arrived in the region after a forced march with his army through Anatolia, forcing Manjūtakīn to lift the siege and return to Damascus. Before another Fatimid expedition could be sent, Basil II negotiated a one-year truce with the caliph, which the Fatimids used to recruit and build new ships for their fleet. In 996 many of the ships were destroyed by a fire at al-Maqs, the port on the Nile near Fustat, further delaying the expedition. Finally, in August 996 al-Aziz died and the objective of Aleppo became secondary to other concerns.

The Zirids in the Maghreb
Before leaving for Egypt, al-Mu'izz had installed Buluggin ibn Ziri, the son of Ziri bn Manad (who died in 971), as his viceroy in the Maghreb. This established a dynasty of viceroys, with the title of "amir", who ruled the region on behalf of the Fatimids. Their authority remained disputed in the western Maghreb, where the rivalry with the Umayyads and with local Zenata leaders continued. After Jawhar's successful western expedition, the Umayyads returned to northern Morocco in 973 to reassert their authority. Buluggin launched one last expedition in 979–980 that reestablished his authority in the region temporarily, until a final decisive Umayyad intervention in 984–985 put an end to further efforts. In 978 the caliph also gave Tripolitania to Buluggin to govern, though Zirid authority there was later replaced by the local Banu Khazrun dynasty in 1001.

In 988 Buluggin's son and successor al-Mansur moved the Zirid dynasty's base from Ashir (central Algeria) to the former Fatimid capital al-Mansuriyya, cementing the status of the Zirids as more or less de facto independent rulers of Ifriqiya, while still officially maintaining their allegiance to the Fatimid caliphs. Caliph al-Aziz accepted this situation for pragmatic reasons to maintain his own formal status as universal ruler. Both dynasties exchanged gifts and the succession of new Zirid rulers to the throne was officially sanctioned by the caliph in Cairo.

The reign of al-Hakim
After al-Aziz's unexpected death, his young son al-Mansur, 11 years old, was installed on the throne as al-Hakim. Hasan ibn Ammar, the leader of the Kalbid clan in Egypt, a military veteran, and one of the last remaining members of al-Mu'izz's old guard, initially became regent, but he was soon forced to flee by Barjawan, the eunuch and tutor of the young al-Hakim, who took power in his stead. Barjawan stabilized the internal affairs of the empire but refrained from pursuing al-Aziz's policy of expansion towards Aleppo. In the year 1000, Barjawan was assassinated by al-Hakim, who now took direct and autocratic control of the state. His reign, which lasted until his mysterious disappearance in 1021, is the most controversial in Fatimid history. Traditional narratives have described him as either eccentric or outright insane, but more recent studies have tried to provide more measured explanations based on the political and social circumstances of the time.

Among other things, al-Hakim was known for executing his officials when unsatisfied with them, seemingly without warning, rather than dismissing them from their posts as had been traditional practice. Many of the executions were members of the financial administration, which may mean that this was al-Hakim's way of trying to impose discipline in an institution rife with corruption. He also opened the Dar al-'Ilm ("House of Knowledge"), a library for the study of the sciences, which was in line with al-Aziz's previous policy of cultivating this knowledge. For the general population, he was noted for being more accessible and willing to receive petitions in person, as well as for riding out in person among the people in the streets of Fustat. On the other hand, he was also known for his capricious decrees aimed at curbing what he saw as public improprieties. He also unsettled the plurality of Egyptian society by imposing new restrictions on Christians and Jews, particularly on the way they dressed or behaved in public. He ordered or sanctioned the destruction of a number of churches and monasteries (mostly Coptic or Melkite), which was unprecedented, and in 1009, for reasons that remain unclear, he ordered the demolition of the Church of the Holy Sephulchre in Jerusalem.

Al-Hakim greatly expanded the recruitment of Black Africans into the army, who subsequently became another powerful faction to balance against the Kutama, Turks, and Daylamis. In 1005, during his early reign, a dangerous uprising led by Abu Rakwa was successfully put down but had come within striking distance of Cairo. In 1012 the leaders of the Arab Tayyi tribe occupied Ramla and proclaimed the sharif of Mecca, al-Ḥasan ibn Ja'far, as the Sunni anti-caliph, but the latter's death in 1013 led to their surrender. Despite his policies against Christians and his demolition of the church in Jerusalem, al-Hakim maintained a ten-year truce with the Byzantines that began in 1001. For most of his reign, Aleppo remained a buffer state that paid tribute to Constantinople. This lasted until 1017, when the Fatimid Armenian general Fatāk finally occupied Aleppo at the invitation of a local commander who had expelled the Hamdanid ghulām ruler Mansur ibn Lu'lu'. After a year or two, however, Fatāk made himself effectively independent in Aleppo.

Al-Hakim also alarmed his Isma'ili followers in several ways. In 1013 he announced the designation of two great-great-grandsons of al-Mahdi as two separate heirs: one, Abd al-Raḥīm ibn Ilyās, would inherit the title of caliphate as the role of political ruler, and the other, Abbās ibn Shu'ayb, would inherit the imamate or religious leadership. This was a serious departure from a central purpose of the Fatimid Imam-Caliphs, which was to combine these two functions in one person. In 1015 he also suddenly halted the Isma'ili doctrinal lectures of the majālis al-ḥikma ("sessions of wisdom") which had taken place regularly inside the palace. In 1021, while wandering the desert outside Cairo on one of his nightly excursions, he disappeared. He was purportedly murdered, but his body was never found.

Losses, successes, and civil war
After al-Hakim's death his two designated heirs were killed, putting an end to his succession scheme, and his sister Sitt al-Mulk arranged to have his 15-year-old son Ali installed on the throne as al-Zahir. She served as his regent until her death in 1023, at which point an alliance of courtiers and officials ruled, with al-Jarjarā'ī, a former finance official, at their head. Fatimid control in Syria was threatened during the 1020s. In Aleppo, Fatāk, who had declared his independence, was killed and replaced in 1022, but this opened the way for a coalition of Bedouin chiefs from the Banu Kilab, Jarrahids, and Banu Kalb led by Salih ibn Mirdas to take the city in 1024 or 1025 and to begin imposing their control on the rest of Syria. Al-Jarjarā'ī sent Anushtakin al-Dizbari, a Turkish commander, with a force that defeated them in 1029 at the Battle of Uqḥuwāna near Lake Tiberias. In 1030 the new Byzantine emperor Romanos III broke a truce to invade northern Syria and forced Aleppo to recognize his suzerainty. His death in 1034 changed the situation again and in 1036 peace was restored. In 1038 Aleppo was directly annexed by the Fatimids state for the first time.

Al-Zahir died in 1036 and was succeeded by his son, al-Mustansir, who had the longest reign in Fatimid history, serving as caliph from 1036 to 1094. However, he remained largely uninvolved in politics and left the government in the hands of others. He was seven years old at his accession and thus al-Jarjarā'ī continued to serve as vizier and his guardian. When al-Jarjarā'ī died in 1045 a series of court figures ran the government until al-Yāzūrī, a jurist of Palestinian origin, took and kept the office of vizier from 1050 to 1058.

In the 1040s (possibly in 1041 or 1044), the Zirids declared their independence from the Fatimids and recognized the Sunni Abbasid caliphs of Baghdad, which led the Fatimids to launch the devastating Banū Hilal invasions of North Africa. Fatimid suzerainty over Sicily also faded as the Muslim polity there fragmented and external attacks increased. By 1060, when the Italo-Norman Roger I began his conquest of the island (completed in 1091), the Kalbid dynasty, along with any Fatimid authority, were already gone.

There was more success in the east, however. In 1047 the Fatimid Ali Muhammad al-Ṣulayḥi in Yemen built a fortress and recruited tribes with which he was able to capture San'a in 1048. In 1060 he began a campaign to conquer all of Yemen, capturing Aden and Zabid. In 1062 he marched on Mecca, where Shukr ibn Abi al-Futuh's death in 1061 provided an excuse. Along the way he forced the Zaydi Imam in Sa'da into submission. Upon arriving in Mecca, he installed Abu Hashim Muhammad ibn Ja'far as the new sharif and custodian of the holy sites under the suzerainty of the Fatimids. He returned to San'a where he established his family as rulers on behalf of the Fatimid caliphs. His brother founded the city of Ta'izz, while the city of Aden became an important hub of trade between Egypt and India, which brought Egypt further wealth.

Events degenerated in Egypt and Syria, however. Starting in 1060, various local leaders began to break away or challenge Fatimid dominion in Syria. While the ethnic-based army was generally successful on the battlefield, it had begun to have negative effects on Fatimid internal politics. Traditionally the Kutama element of the army had the strongest sway over political affairs, but as the Turkish element grew more powerful, it began to challenge this. In 1062, the tentative balance between the different ethnic groups within the Fatimid army collapsed and they quarreled constantly or fought each other in the streets. At the same time, Egypt suffered a 7-year period of drought and famine known as the Mustansirite Hardship. Viziers came and went in flurry, the bureaucracy broke down, and the caliph was unable or unwilling to assume responsibilities in their absence. Declining resources accelerated the problems among the different ethnic factions, and outright civil war began, primarily between the Turks under Nasir al-Dawla ibn Hamdan, a scion of the Hamdanids of Aleppo, and Black African troops, while the Berbers shifted alliance between the two sides. The Turkish faction under Nasir al-Dawla seized partial control of Cairo but their leader was not given any official title. In 1067–1068 they plundered the state treasury and then looted any treasures they could find in the palaces. The Turks turned against Nasir al-Dawla in 1069, but he managed to rally Bedouin tribes to his side, took over most of the Nile Delta region, and blocked supplies and food from reaching the capital from this region. Things degenerated further for the general population, especially in the capital, which relied on the countryside for food. Historical sources of this period report extreme hunger and hardship in the city, even to the point of cannibalism. The depredations in the Nile Delta may have also been a turning point that accelerated the long-term decline of the Coptic community in Egypt.

Badr al-Jamali and the Fatimid revival
By 1072, in a desperate attempt to save Egypt, al-Mustansir recalled general Badr al-Jamali, who was at the time the governor of Acre. Badr led his troops into Egypt, entered Cairo in January 1074, and successfully suppressed the different groups of the rebelling armies. As a result, Badr was made vizier, becoming one of the first military viziers (امير الجيوش) who would dominate late Fatimid politics. In 1078 al-Mustansir formally abdicated responsibility for all state affairs to him. His de facto rule initiated a temporary and limited revival of the Fatimid state, although it was now faced with serious challenges. Badr reestablished Fatimid authority in the Hejaz (Mecca and Medina) and the Sulayhids were able to hold on in Yemen. Syria, however, saw the advance of the Sunni-aligned Seljuk Turks who had conquered much of the Middle East and had become the guardians of the Abbasid Caliphs as well as independent Turkmen groups. Atsiz ibn Uwaq, a Turkmen of the Nawaki tribe, conquered Jerusalem in 1073 and Damascus in 1076 before attempting to invade even Egypt itself. After defeating him at a battle close to Cairo, Badr was able to start a counter-offensive to secure coastal cities, such as Gaza and Ascalon, and later Tyre, Sidon, and Byblos further north in 1089.

Badr made major reforms to the state, updating and simplifying the administration of Egypt. As he was of Armenian background, his term also saw a large influx of Armenian immigrants, both Christian and Muslim, into Egypt. The Armenian church, patronised by Badr, established itself in the country along with a clerical hierarchy. He commanded a large contingent of Armenian troops, many (if not all) of whom were also Christian. Badr also used his relations and influence with the Coptic Church for political advantage. In particular, he enlisted Cyril II (Coptic Pope from 1078 to 1092 ) to secure the allegiance of the Christian kingdoms of Nubia (specifically Makuria) and Ethiopia (specifically the Zagwe dynasty) as vassals to the Fatimid state.

The Juyushi Mosque (الجامع الجيوشي), was commissioned by Badr and completed in 1085 under the patronage of the caliph. The mosque, identified as a mashhad, was also a victory monument commemorating vizier Badr's restoration of order for al-Mustansir. Between 1087 and 1092, the vizier also replaced the mudbrick walls of Cairo with new stone walls and slightly expanded the city. Three of its monumental gates still survive today: Bab Zuweila, Bab al-Futuh, and Bab al-Nasr.

Final decline
As the military viziers effectively became heads of state, the Caliph himself was reduced to the role of a figurehead. The reliance on the Iqta system also ate into Fatimid central authority, as more and more the military officers at the further ends of the empire became semi-independent.

Badr al-Jamali died in 1094 (along with Caliph al-Mustansir that same year) and his son Al-Afdal Shahanshah succeeded him in power as vizier. After al-Mustansir, the Caliphate passed on to al-Musta'li, and after his death in 1101 it passed to the 5-year-old al-Amir. Another of al-Mustansir's sons, Nizar, attempted to take the throne after his father's death and organized a rebellion in 1095, but he was defeated and executed that same year. Al-Afdal arranged for his sister to marry al-Musta'li and later for his daughter to marry al-Amir, hoping in this way to merge his family with that of the caliphs. He also attempted to secure the succession of his son to the vizierate as well, but this ultimately failed.

During al-Afdal's tenure (1094–1121) the Fatimids faced a new external threat: the First Crusade. Although initially both sides intended to reach an agreement and an alliance against the Seljuk Turks, these negotiations would eventually break down. First contact seems to have been established by the crusaders who sent in May or June 1097, on suggestion of Byzantine Emperor Alexios Komnenos, an embassy to al-Afdal. In return the Fatimids dispatched an embassy to the crusading forces which arrived in February 1098 during their siege of Antioch, witnessing and congratulating the crusaders on their victory against the Seljuk emirs Ridwan of Aleppo and Sökmen of Jerusalem as well as stressing their friendly attitude towards Christians. The Fatimid embassy stayed for a month with the crusading forces before returning via the harbour of Latakia with gifts as well as Frankish ambassadors. It is uncertain whether an agreement was reached but it seems that the parties expected to reach a conclusion in Cairo. Al-Afdal took then advantage of the crusader victory at Antioch to reconquer Jerusalem in August 1098, possibly to be in a better position in the negotiations with the crusaders. The next time both parties met was at Arqah in April 1099 where an impasse was reached in regard to the question of ownership over Jerusalem. Following this, the crusaders crossed into Fatimid territory and captured Jerusalem in July 1099 while al-Afdal was leading a relief army trying to reach the city. The two forces finally clashed in the Battle of Ascalon in which al-Afdal was defeated. Nevertheless, the initial negotiations were held against the Fatimids and Ibn al-Athir wrote that it was said that the Fatimids had invited the crusaders to invade Syria.

This defeat established the Kingdom of Jerusalem as a new regional rival and although many crusaders returned to Europe, having fulfilled their vows, the remaining forces, often aided by the Italian maritime republics, overran much of the coastal Levant, with Tripoli, Beirut, and Sidon falling to them between 1109 and 1110. The Fatimids retained Tyre, Ascalon, and Gaza with the help of their fleet. After 1107, a new rising star rose through the ranks of the regime in the form of Muḥammad ʿAlī bin Fatik, better known as al-Maʾmūn al-Baṭā'iḥī. He managed to carry out various administrative reforms and infrastructural projects in the later years of al-Afdal's term, including the construction of an astronomical observatory in 1119. Al-Afdal's was assassinated in 1121, an act blamed on the Nizaris or Assassins, though the truth of this is unconfirmed.

Al-Baṭā'iḥī took al-Afdal's place as vizier, but unlike his predecessors he had less support in the army and was ultimately reliant on the caliph for power. In 1124 he lost Tyre to the Crusaders. He was also responsible for constructing a small but notable mosque in Cairo, the Al-Aqmar Mosque, which was completed in 1125 and has largely survived to the present day. That same year, however, Caliph al-Amir had him arrested, probably due to his failure to resist the Crusaders or due to the caliph's resentment of his wealth and power. Three years later he was executed. Al-Amir then ruled the Caliphate personally, briefly interrupting the long period of de facto rule by the caliph's viziers. Al-Amir himself was assassinated in 1130, probably by the Nizari Assassins.

Al-Amir apparently had a son born shortly before his death, known as al-Ṭayyib. One of Al-Amir's cousins (a grandson of al-Mustansir), Abd al-Majid, had himself appointed regent. Under pressure from the army, one of al-Afdal's sons, Abu Ali Ahmad (known as Kutayfāt), was appointed vizier with titles similar to al-Adal and Badr al-Jamali. Kutayfāt attempted to depose the Fatimid dynasty by imprisoning Abd al-Majid and by declaring himself to be the representative of Muhammad al-Muntazar, the "hidden" Imam awaited by Twelver Shi'as. The coup did not last long, as Kutayfāt was assassinated in 1131 by al-Amir's followers in the Fatimid establishment. Abd al-Majid was released and resumed his role as regent. In 1132, however, he declared himself to be the new Imam-Caliph, taking the title of al-Hafiz, sidelining the infant al-Ṭayyib and breaking with the tradition of the succession passing directly from father to son. Most of the Fatimid lands acknowledged his succession, but the Sulayhids in Yemen did not and broke away from the Caliphate in Cairo, recognizing al-Ṭayyib as the true Imam. This caused another schism between the Hafizi and Tayyibi branches of the Musta'li Isma'ilis.

In 1135 al-Hafiz was pressured by the Fatimid Armenian troops into appointing Bahram, a Christian Armenian, to the office of vizier. Opposition from Muslim troops forced him to leave in 1137, when Ridwan, a Sunni Muslim, was appointed vizier. When Ridwan began to plot the deposition of al-Hafiz, he was expelled from Cairo and later defeated in battle. He accepted a pardon from the caliph and remained at the palace. Al-Hafiz chose not to appoint another vizier, and instead took direct control of the state until his death in 1149. During this time, the fervor of the Isma'ili religious cause in Egypt had significantly faded, and political challenges to the caliph became more common. Sunni Muslims were also increasingly appointed to high posts. The Fatimid dynasty largely continued to survive due to the established common interests that many factions and elites had in maintaining the current system of government.

Al-Hafiz was the last Fatimid caliph to rule directly and the last one to ascend to the throne as an adult. The last three caliphs, al-Zafir (r. 1149–1154), al-Fa'iz (r. 1154–1160), and al-Adid (r. 1160–1171), were all children when they came to the throne. Under al-Zafir, an elderly Berber named Ibn Masal was initially vizier, per the instructions left by Al-Hafiz. The army, however, supported a Sunni named Ibn Sallar instead, whose supporters managed to defeat and kill Ibn Masal in battle. After negotiating with the women of the palace, Ibn Sallar was installed as vizier in 1150. In January 1153, the Crusader king Baldwin III of Jerusalem besieged Ascalon, the last remaining Fatimid foothold in the Levant. In April, Ibn Sallar was murdered in a plot organized by Abbas, his stepson, and Abbas's son, Nasr. As no relieving force arrived, Ascalon surrendered in August, on the condition that the inhabitants could leave safely for Egypt. It was on this occasion that the head of Husayn was allegedly brought from Ascalon to Cairo, where it was housed in what is now the al-Hussein Mosque. The next year (1154), Nasr murdered al-Zafir, and Abbas, now vizier, declared his 5-year-old son 'Isa (al-Fa'iz) the new caliph. The women of the palace intervened, calling on Ṭalā'i' ibn Ruzzīk, a Muslim Armenian governor in Upper Egypt, to help. Tala'i drove out Abbas and Nasr from Cairo and became vizier that same year. Afterwards he also conducted renewed operations against the Crusaders, but he could do little more than harass them by sea. Al-Fa'iz died in 1160 and Tala'i was assassinated in 1161 by Sitt al-Qusur, a sister of al-Zafir. Tala'i's son, Ruzzīk ibn Ṭalā'i', held the office of vizier until 1163, when he was overthrown and killed by Shawar, the governor of Qus.

As vizier, Shawar came into conflict with his rival, the Arab general Dirgham. The internal disorder of the Caliphate attracted the attention and meddling of the Sunni Zengid ruler Nūr ad-Dīn, who was now in control of Damascus and a large part of Syria, and of the King of Jerusalem, Amalric I. The Crusaders had already forced Tala'i ibn Ruzzik to pay them a tribute in 1161 and had made an attempt to invade Egypt in 1162. When Shawar was driven out of Cairo by Dirgham in 1163, he sought refuge and help with Nur al-Din. Nur al-Din sent his general, Asad al-Din Shirkuh, to seize Egypt and reinstall Shawar as vizier. The accomplished this task in the summer of 1164, when Dirgham was defeated and killed.

Shawar's remaining years continued in chaos as he made shifting alliances with either the King of Jerusalem or with Nur al-Din, depending on circumstances. In 1167 the Crusaders pursued Shirkuh's forces in to Upper Egypt. In 1168 Shawar, worried about the possible Crusader capture of Cairo, infamously set fire to Fustat in an attempt to deny the Crusaders a base from which to besiege the capital. After forcing the Crusaders to leave Egypt again, Shirkuh finally had Shawar murdered in 1169, with the agreement of Caliph al-Adid. Shirkuh himself was appointed as al-Adid's vizier, but he died unexpectedly two months later. The position passed to his nephew, Salah ad-Din Yusuf ibn Ayyub (known in the West as Saladin). Salah ad-Din was openly pro-Sunni and suppressed the Shi'a call to prayer, ended the Isma'ili doctrinal lectures (the majālis al-ḥikma), and installed Sunni judges. He finally and officially deposed al-Adid, the last Fatimid caliph, in September 1171. This ended the Fatimid dynasty and began the Ayyubid Sultanate of Egypt and Syria.

Dynasty
White was the dynastic colour of the Fatimids, in opposition to Abbasid black, while red and yellow banners were associated with the Fatimid caliph's person. Green is also cited as their dynastic colour, based on a tradition that the Islamic prophet Muhammad wore a green cloak.

Caliphs

 * 1) Abū Muḥammad ʿAbdallāh al-Mahdī bi'llāh (909–934), founder of the Fatimid dynasty
 * 2) Abū'l-Qāsim Muḥammad al-Qā'im bi-Amr Allāh (934–946)
 * 3) Abū Ṭāhir Ismāʿil al-Manṣūr bi-Naṣr Allāh (946–953)
 * 4) Abū Tamīm Maʿadd al-Muʿizz li-Dīn Allāh (953–975). Egypt is conquered during his reign.
 * 5) Abū Manṣūr Nizār al-ʿAzīz bi-llāh (975–996)
 * 6) Abū ʿAlī al-Manṣūr al-Ḥākim bi-Amr Allāh (996–1021). The Druze religion is founded during his lifetime.
 * 7) Abū'l-Ḥasan ʿAlī al-Ẓāhir li-Iʿzāz Dīn Allāh (1021–1036)
 * 8) Abū Tamīm Ma'add al-Mustanṣir bi-llāh (1036–1094). Quarrels over his succession led to the Nizari split.
 * 9) Abū'l-Qāsim Aḥmad al-Musta'lī bi-llāh (1094–1101)
 * 10) Abū ʿAlī Manṣūr al-Āmir bi-Aḥkām Allāh (1101–1130). The Fatimid rulers of Egypt after him are not recognized as Imams by Mustaali/Taiyabi Ismailis.
 * 11) Abu'l-Maymūn ʿAbd al-Majīd al-Ḥāfiẓ li-Dīn Allāh (1130–1149). The Hafizi sect is founded with Al-Hafiz as Imam.
 * 12) Abū Manṣūr Ismāʿil al-Zāfir bi-Amr Allāh (1149–1154)
 * 13) Abū'l-Qāsim ʿĪsā al-Fā'iz bi-Naṣr Allāh (1154–1160)
 * 14) Abū Muḥammad ʿAbdallāh al-ʿĀḍid li-Dīn Allāh (1160–1171)

Consorts

 * 1) Rasad, wife of the seventh caliph Ali al-Zahir and mother of the eighth caliph al-Mustansir bi-llāh.

Burial place
The Fatimid caliphs were buried in a mausoleum known as Turbat az-Za'faraan ("the Saffron Tomb"), located at the southern end of the eastern Fatimid palace in Cairo on the site now occupied by the Khan el-Khalili market. The remains of the early Fatimid caliphs in Ifriqiya were also transferred here when al-Mu'izz moved his capital to Cairo. However, the mausoleum was completely demolished by the Mamluk amir Jaharkas al-Khalili in 1385 to make way for the construction of a new merchant building (which gave its name to the present-day market). During the demolition, Jaharkas reportedly desecrated the bones of the Fatimid royal family by having them dumped into the rubbish hills east of the city.

Religious communities
Fatimid society was highly pluralistic. Isma'ili Shi'ism was the religion of the state and the caliph's court, but most of the population followed different religions or denominations. Most of the Muslim population remained Sunni, and a large part of the population remained Christian. Jews were a smaller minority. As in other Islamic societies of the time, non-Muslims were classified as dhimmis, a term which implied both certain restrictions and certain liberties, though the practical circumstances of this status varied from context to context. As elsewhere in the historic Muslim world, they were required to pay the jizya tax. Scholars generally agree that, on the whole, Fatimid rule was highly tolerant and inclusive towards different religious communities.

Unlike western European governments of the era, advancement in Fatimid state offices was more meritocratic than hereditary. Members of other branches of Islam, like the Sunnis, were just as likely to be appointed to government posts as Shiites. Tolerance was extended to non-Muslims, such as Christians and Jews, who occupied high levels in government based on ability, and this policy of tolerance ensured the flow of money from non-Muslims in order to finance the Caliphs' large army of Mamluks brought in from Circassia by Genoese merchants.

There were exceptions to this general attitude of tolerance, however, most notably by Al-Hakim, though this has been highly debated, with Al-Hakim's reputation among medieval Muslim historians conflated with his role in the Druze faith. Christians in general and Copts in particular were persecuted by Al-Hakim;  the persecution of the Christians included closing and demolishing churches and forced conversion to Islam. With the succession of Caliph al-Zahir, the Druze faced a mass persecution, which included large massacres against the Druze in Antioch, Aleppo, and other cities.

Isma'ilis
It's unclear what number or percentage of the population inside the caliphate were actually Isma'ilis, but they always remained a minority. Historical chronicles report large numbers of enthusiastic converts in Egypt during the reign of al-'Aziz, but this trend dropped significantly around the middle of al-Hakim's reign. The Fatimid state promoted Isma'ili doctrine (the da'wa) through a hierarchical organization. The Imam-Caliph, as successor to the Prophet Muhammad, was both the political and religious leader. Below the Imam-Caliph, the top of this hierarchy was headed by the dā'ī l-du'āt or "supreme missionary". Newcomers to the doctrine were initiated by attending the majālis al-ḥikma ("Sessions of Wisdom"), lectures and lessons that were delivered in a special hall inside the palaces of Cairo. The doctrine was kept secret from those who were not initiated. Additionally, Isma'ili doctrines were disseminated through the lectures hosted at Al-Azhar Mosque in Cairo, which became an intellectual center hosting teachers and students. Beyond the borders of the Fatimid Caliphate, recruitment to the da'wa continued to be performed in secret as it had been before the caliphate's establishment, though the many missionaries maintained contact with the leadership in Ifriqiya or Egypt. Some of the da'is (missionaries) abroad sometimes came to Cairo and became important figures in the state, as with the example of al-Kirmani during al-Hakim's reign.

Isma'ili unity was weakened over time by several schisms after the establishment of the caliphate (in addition to the Qarmatian schism before its establishment). The Druze, who believed in the divinity of Caliph al-Hakim, were suppressed in Egypt and elsewhere, but eventually found a home in the region of Mount Lebanon. After the death of Caliph al-Mustansir, a succession crisis resulted in the breakaway of the Nizaris, who supported the claim of his oldest son Nizar, as opposed to the Musta'lis who supported the successful enthronement of al-Musta'li. The Nizaris were also suppressed inside the Caliphate's borders, but continued to be active outside it, mostly in Iran, Iraq, and parts of Syria. After the death of Caliph al-Amir, al-Hafiz, his cousin, successfully claimed the title of Imam-Caliph at the expense of al-Amir's infant son, al-Tayyib. Those who recognized al-Hafiz in Cairo were known as the al-Hafizi branch, but those who opposed this unusual succession and supported the succession of al-Tayyib were known as the al-Tayyibi branch. This particular schism resulted in the loss of Fatimid support in Yemen.

Other Muslims
In Ifriqiya, the Sunni Muslims of the cities largely followed the Maliki school or madhhab. The Maliki school had become predominant here during the eighth century at the expense of the Hanafi school, which had generally been favoured by the Aghlabids. In Egypt, the majority of Muslims were Sunni and remained so throughout the Fatimid period. Cognizant of this, the Fatimid authorities introduced Shi'a changes to religious rituals only gradually after Jawhar's conquest. It was also in this era that the followers of the Hanafi, Shafi'i, Hanbali, and Maliki schools were beginning to think of themselves collectively, to one extent or another, as Sunni, which undermined the universalism that the Shi'a Isma'ilis promoted. Some Shi'as, including some Hasanid and Husaynid families, were also present in Egypt and welcomed the Fatimids as fellow Shi'as or as blood relatives, but without necessarily converting to Isma'ilism. Many non-Isma'ili Muslims also accepted the Fatimid caliphs as having legitimate rights to lead the Muslim community but did not accept the more absolute Shi'a beliefs in the concept of the Imamate.

Christians
Christians may have still constituted a majority of the population in Egypt during the Fatimid period, although scholarly estimates on this issue are tentative and vary between authors. The proportion of Christians would have likely been greater in the rural population than in the main cities. Among Christians, the largest community were Copts, followed by Melkite Christians. A large number of Armenian immigrants also arrived in Egypt during the late 11th and early 12th centuries when Armenian viziers like Badr al-Jamali dominated the state, which led to the Armenian church establishing a foothold in the country as well. In addition to churches in towns and cities, Christian monasteries also dotted the countryside. Some regions, like Wadi al-Natrun, were ancient centres of Coptic monasticism. Italian traders, led by Amalfitans, were also present in Fustat and Alexandria, moving goods between Egypt and the rest of the Mediterranean world.

Within the Christian communities, and especially among Copts, there emerged a relatively affluent class of notables who served as scribes or administrators in the Fatimid regime. These laymen used their wealth to patronize, and in turn influence, their churches. The state also had influence on the church, as demonstrated by the transfer of the Coptic Patriarchate from Alexandria to Fustat (specifically what is now Old Cairo) during the patriarchate of Cyril II (1078–1092), due to the demands of Badr al-Jamali, who wished for the Coptic pope to stay close to the capital. The Church of the Virgin, now known as the Hanging Church, became the new seat of the Patriarchate, along with an alternative church compound built on the upper floor of the St. Mercurius Church. Until the 14th century (when the seat was moved to the Church of the Virgin Mary in Harat Zuwayla), both churches were residences of the Coptic pope and served as venues for the consecrations of new popes and other important religious events.

Jews
Jewish communities existed across the territories under Fatimid control and also enjoyed a degree of self-governance. Although a smaller minority compared to Christians and Muslims, their history is relatively well-documented thanks to the Genizah documents. The community was divided between Rabbanites and Karaites. Traditionally, up until the late 11th century, the most powerful head of the Jewish community was the ga'on or leader of the yeshiva of Jerusalem, who appointed judges and other Jewish community officials across the region. The Fatimids formally charged the ga'on of Jerusalem with responsibilities as representative of the community. By 1100, however, a new position was established by Egyptian Jews in Fustat, known as the "Head of the Jews" or as the nagid. This official in the Egyptian capital became recognized afterward as the head and representative of the Jewish community in its dealings with the Fatimid state. This shift was likely due to the Jerusalem ga'on 's own loss of influence and to the Jewish community's engagement with the centralizing politics that Badr al-Jamali pursued around this time (which had already resulted in the transfer of the Coptic Patriarchate to Fustat).

Language
Religious diversity notwithstanding, the spread of Arabic as the main language of the population had already progressed rapidly before the Fatimid period. In parts of Egypt, Copts and possibly also some Muslim communities were still speaking Coptic when the Fatimids arrived on the scene. It is during the Fatimid period, however, that Coptic religious culture began to be translated into Arabic. By the end of the Fatimid period (12th century), many Coptic Christians could no longer understand the Coptic language, and eventually its usage was reduced to a liturgical language.

Military system
The Fatimid military was based largely on the Kutama Berber tribesmen brought along on the march to Egypt, and they remained an important part of the military even after Ifriqiya began to break away.

A fundamental change occurred when the Fatimid Caliphate attempted to push into Syria in the latter half of the tenth century. The Fatimids were faced with the now Turkish-dominated forces of the Abbasid Caliphate and began to realize the limits of their current military. Thus during the reign of al-Aziz Billah and al-Hakim bi-Amr Allah, the Caliph began incorporating armies of Turks and, later, black Africans (even later, other groups such as Armenians were also used). The army units were generally separated along ethnic lines: the Berbers were usually the light cavalry and foot skirmishers, while the Turks were the horse archers or heavy cavalry (known as Mamluks). The black Africans, Syrians, and Arabs generally acted as the heavy infantry and foot archers. This ethnic-based army system, along with the partial slave status of many of the imported ethnic fighters, would remain fundamentally unchanged in Egypt for many centuries after the fall of the Fatimid Caliphate.

The Fatimids focused their military on the defence of the empire as threats presented, which they were able to repel. In the mid-10th century, the Byzantine Empire was ruled by Nikephoros II Phokas, who had destroyed the Muslim Emirate of Crete in 961 and conquered Tartus, Al-Masaisah, 'Ain Zarbah, among other areas, gaining complete control of Iraq and the Syrian borders, and earning the sobriquet "The Pale Death of the Saracens". With the Fatimids, however, he proved less successful. After renouncing his payments of tribute to the Fatimid caliphs, he sent an expedition to Sicily, but was forced by defeats on land and sea to evacuate the island completely. In 967, he made peace with the Fatimids and turned to defend himself against their common enemy, Otto I, who had proclaimed himself Roman Emperor and had attacked Byzantine possessions in Italy.

Al-Mahdiyya
Al-Mahdiyya, the first capital of the Fatimid dynasty, was established by its first caliph, 'Abdullāh al-Mahdī (297–322 AH/909–934 CE) in 300 AH/912–913 CE. The caliph had been residing in nearby Raqqada but chose this new and more strategic location in which to establish his dynasty. The city of al-Mahdiyya is located on a narrow peninsula along the coast of the Mediterranean Sea, east of Kairouan and just south of the Gulf of Hammamet, in modern-day Tunisia. The primary concern in the city's construction and locale was defense. With its peninsular topography and the construction of a wall 8.3 m thick, the city became impenetrable by land. This strategic location, together with a navy that the Fatimids had inherited from the conquered Aghlabids, made the city of Al-Mahdiyya a strong military base where ʿAbdullāh al-Mahdī consolidated power and planted the seeds of the Fatimid caliphate for two generations. The city included two royal palaces – one for the caliph and one for his son and successor al-Qāʾim – as well as a mosque, many administrative buildings, and an arsenal.

Al-Mansuriyya
Al-Manṣūriyya (also known as Ṣabra al-Manṣūriyya ) was established between 334 and 336 AH (945 and 948 CE) by the third Fatimid caliph al-Manṣūr (334–41 AH/946–53 CE) in a settlement known as Ṣabra, located on the outskirts of Kairouan in modern-day Tunisia. The new capital was established in commemoration of the victory of al-Manṣūr over the Khārijite rebel Abū Yazīd at Ṣabra. Construction of the city was not quite finished when al-Manṣūr died in 953, but his son and successor, al-Muʿizz, finished it and completed the city's mosque that same year. Like Baghdad, the plan of the city of Al-Manṣūriyya is round, with the caliphal palace at its center. Due to a plentiful water source, the city grew and expanded a great deal under al-Manṣūr. Archaeological evidence suggests that there were more than 300 hammams built during this period in the city as well as numerous palaces. When al-Manṣūr's successor, al-Mu'izz, moved the caliphate to Cairo he left his deputy, Buluggin ibn Ziri, as regent of Ifriqiya, marking the beginning of the city's Zirid period. In 1014–15 the Zirid ruler Badis ibn al-Mansur ordered merchants and artisans of Kairouan to be transferred to al-Manṣūriyya, which may have helped provoke a revolt in 1016 which damaged the city. In 1057, under pressure from the Banu Hilal invasions, the Zirids abandoned al-Manṣūriyya for Mahdiyya and the city was devastated. Unlike Kairouan, it remained in ruins afterwards and was never revived. The site was pillaged over time. Modern archeological excavations here began in 1921.

Cairo
Cairo was established by the fourth Fatimid caliph, al-Mu'izz, in 359 AH/970 CE and remained the capital of the Fatimid caliphate for the duration of the dynasty. The city was officially named al-Qāhirah al-Mu'izziyya (القاهرة المعزية), which can be translated as the "Victorious City of al-Mu'izz", known afterward simply as al-Qāhira and giving us the modern English name "Cairo". Cairo can thus be considered the capital of Fatimid cultural production. Though the original Fatimid palace complex, including administrative buildings and royal residents, no longer exists, modern scholars can glean a good idea of the original structure based on the Mamluk-era account of al-Maqrīzī. Perhaps the most important of Fatimid monuments outside the palace complex is the mosque of al-Azhar (359–61 AH/970–72 CE) which still stands today, though the building was significantly expanded and modified in later periods. Likewise the important Fatimid mosque of al-Ḥākim, built from 380 to 403 AH/990-1012 CE under two Fatimid caliphs, was significantly rebuilt and renovated in the 1980s. Cairo remained the capital for, including al-Muʿizz, eleven generations of caliphs, after which the Fatimid Caliphate finally fell to Ayyubid forces in 567 AH/1171 CE.

Art and architecture
The Fatimids were known for their exquisite arts. The Fatimid period is important in the history of Islamic art and architecture as it is one of the earliest Islamic dynasties for which enough materials survive for a detailed study of their evolution. The stylistic diversity of Fatimid art was also a reflection of the wider cultural environment of the Mediterranean world at this time. The most notable characteristics of their decorative arts are the use of lively figurative motifs and the use of an angular, floriated Kufic script for Arabic inscriptions. Among the best-known art forms that flourished are a type of ceramic lustreware and the crafting of objects carved in solid rock crystal. The dynasty also sponsored the production of linen textiles and a tiraz workshop. A vast collection of different luxury objects once existed within the caliph's palaces, but few examples of them have survived to the present day.

Many traces of Fatimid architecture exist in both Egypt and present-day Tunisia, particularly in the former capitals of Mahdia (al-Mahdiyya) and Cairo (al-Qahira). At Mahdia, the most important surviving monument is Great Mosque. In Cairo, prominent examples include the Al-Azhar Mosque and the Al-Hakim Mosque, as well as the smaller monuments of al-Aqmar Mosque, the Mashhad of Sayyida Ruqayya, and the Mosque of al-Salih Tala'i. Al-Azhar Mosque, which was also a center of learning and teaching known today as al-Azhar University, was named in honour of Fatimah (the daughter of Muhammad from whom the Fatimids claimed descent), who was called Az-Zahra (the brilliant). There were two main Fatimid palaces in Cairo, covering a huge area around Bayn al-Qasrayn, near Khan el-Khalili. Parts of the city walls constructed by Badr al-Jamali – most notably three of its gates – also survive.

Important figures
List of important figures:


 * Abu Abdallah al-Shi'i (d. After 911)
 * Abu Yaqub al-Sijistani (d. After 971)
 * Al-Qadi al-Nu'man (d. 974)
 * Hamid al-Din al-Kirmani (d. After 1020)
 * Hakim Nasir-i Khusraw (d. After 1070)
 * Al-Mu'ayyad fi'l-Din al-Shirazi (d. 1078)
 * Al-Sayyida al-Mu'iziyya (also known as Durzan)

Legacy
After Al-Mustansir Billah, his sons Nizar and Al-Musta'li both claimed the right to rule, leading to a split into the Nizari and Musta'li factions respectively. Nizar's successors eventually came to be known as the Aga Khan, while Musta'li's followers eventually came to be called the Dawoodi bohra.

The Fatimid dynasty continued and flourished under Al-Musta'li until Al-Amir bi-Ahkami'l-Lah's death in 1130. Leadership was then contested between At-Tayyib Abu'l-Qasim, Al-Amir's two-year-old son, and Al-Hafiz, Al-Amir's cousin whose supporters (Hafizi) claimed Al-Amir died without an heir. The supporters of At-Tayyib became the Tayyibi Isma'ilis. At-Tayyib's claim to the imamate was endorsed by Arwa al-Sulayhi, Queen of Yemen. In 1084, Al-Mustansir had Arwa designated a hujjah (a holy, pious lady), the highest rank in the Yemeni Da'wah. Under Arwa, the Da'i al-Balagh (the imam's local representative) Lamak ibn Malik and then Yahya ibn Lamak worked for the cause of the Fatimids. After At-Tayyib's disappearance, Arwa named Dhu'ayb bin Musa the first Da'i al-Mutlaq with full authority over Tayyibi religious matters. Tayyibi Isma'ili missionaries (in about 1067 AD (460 AH)) spread their religion to India, leading to the development of various Isma'ili communities, most notably the Alavi, Dawoodi, and Sulaymani Bohras. Syedi Nuruddin went to Dongaon to look after southern India and Syedi Fakhruddin went to East Rajasthan.