After defeating internal enemies ‘Obaidallah turned his attention to the remaining ‘Abbāsid possessions in Africa, and his general Habāsah b. Yūsuf in the year 913 advanced along the northern coast, taking various places, including the important town of Barca, his progress, it is said, being marked by great cruelty. He then advanced towards Egypt, and towards the end of July 914, being reinforced by Abu’l-Qāsim, afterwards al-Qā’im, entered Alexandria. The danger led to measures of unusual energy being taken by the Bagdad caliph Moqtadir, an army being sent to Egypt under Mu‘nis, and a special post being organized between that country and Bagdad to convey messages uninterruptedly. The Fatimite forces were defeated, partly owing to the insubordination of the general Habāsah, in the winter of 914, and returned to Barca and Kairawān with great loss.
A second expedition was undertaken against Egypt in the year 919, and on the 10th of July Alexandria was entered by Abu’l-Qāsim, who then advanced southward, seizing the Fayum and Ushmūnain (Eshmunain). He was presently reinforced by a fleet, which, however, was defeated at Rosetta in March of the year 920 by a fleet despatched from Tarsus by the ‘Abbāsid caliph Moqtadir, most of the vessels being burned. Through the energetic measures of the caliph, who sent repeated reinforcements to Fostat, Abu’l-Qāsim was compelled in the spring of 921 to evacuate the places which he had seized, and return to the west with the remains of his army, which had suffered much from plague as well as defeat on the field. On his return he found that the court had migrated from Raqqāda to the new capital Mahdia (q.v.). Meanwhile other expeditions had been despatched by ‘Obaidallah towards the west, and Nekor (Nakur) and Fez had been forced to acknowledge his sovereignty.
The remaining years of ‘Obaidallah’s reign were largely spent in dealing with uprisings in various parts of his dominions, the success of which at times reduced the territory in which he was recognized to a small area.
‘Obaidallah died on the 4th of March 933, and was succeeded by Abu’l-Qāsim, who took the title al-Qā’im biamr allah. He immediately after his accession occupied himself with the reconquest of Fez and Nekor, which had revolted during the last years of the former caliph. He also despatched a fleet under Ya‘qūb b. Isḥāq, which ravaged the coast of France, took Genoa, and plundered the coast of Calabria before returning to Africa. A third attempt made by him to take Egypt resulted in a disastrous defeat at Dhāt al-Humān, after which the remains of the expedition retreated in disorder to Barca.
The later years of the reign of Qā’im were troubled by the uprising of Abū Yazīd Makhlad al-Zenātī, a leader who during the former reign had acquired a following among the tribes inhabiting the Jebel Aures, including adherents of the ‘Ibādī sect. After having fled for a time to Mecca, this person returned in 937 to Tauzar (Touzer), the original seat of his operations, and was imprisoned by Qā’im’s order. His sons, aided by the powerful tribe Zenāta, succeeded in forcing the prison, and releasing their father, who continued to organize a conspiracy on a vast scale, and by the end of 943 was strong enough to take the field against the Fatimite sovereign, whom he drove out of Kairawān. Abū Yazīd proclaimed himself a champion of Sunnī doctrine against the Shī‘is, and ordered the legal system of Malik to be restored in place of that introduced by the Fatimites. Apparently the doctrines of the latter has as yet won little popularity, and Abū Yazīd won an enormous following, except among the Kutāma, who remained faithful to Qā’im. On the last day of October 944, an engagement was fought between Kairawān and Mahdia at a place called al-Akhawān, which resulted in the rout of Qā’im’s forces, and the caliph’s being shortly after shut up in his capital, the suburbs of which he defended by a trench. Abū Yazīd’s forces were ill-suited to maintain a protracted siege, and since, owing to the former caliph’s forethought, the capital was in a condition to hold out for a long time, many of them deserted and the besiegers gained no permanent advantage. After the siege had lasted some ten months Abū Yazīd was compelled to raise it (September 945); the struggle, however, did not end with that event, and for a time the caliph and Abū Yazīd continued to fight with varying fortune, while anarchy prevailed over most of the caliph’s dominions. On the 13th of January 946, Abū Yazīd shut up Qā’im’s forces in Susa which he began to besiege, and attempted to take by storm.
On the 18th of May 945, while Abū Yazīd was besieging Susa, the caliph al-Qā’im died at Mahdia, and was succeeded by his son Ismā’īl, who took the title Manṣūr. He almost immediately relieved Susa by sending a fleet, which joining with the garrison inflicted a severe defeat on Abū Yazīd, who had to evacuate Kairawān also; but though the cities were mainly in the hands of Fatimite prefects, Abū Yazīd was able to maintain the field for more than two years longer, while his followers were steadily decreasing in numbers, and he was repeatedly driven into fastnesses of the Sahara. In August 947 his last stronghold was taken, and he died of wounds received in defending it. His sons carried on some desultory warfare against Manṣūr after their father’s death. A town called Manṣūra or Ṣābrā was built adjoining Kairawān to celebrate the decisive victory over Abū Yazīd, which, however, did not long preserve its name. The exhausted condition of north-west Africa due to the protracted civil war required some years of peace for recuperation, and further exploits are not recorded for Manṣūr, who died on the 19th of March 952.
His son, Abū Tamīm Ma‘add, was twenty-two years of age at the time, and succeeded his father with the title Mo‘izz lidīn allah. His authority was acknowledged over the greater part of the region now constituting Morocco, Algeria and Tunisia, as well as Sicily, and he appears to have had serious thoughts of endeavouring to annex Spain. At an early period in his reign he made Jauhar, who had been secretary under the former caliph, commander of the forces, and the services rendered by this person to the dynasty made him count as its second founder after al-Shī‘ī. In the years 958 and 959 he was sent westwards to reduce Fez and other places where the authority of the Fatimite caliph had been repudiated, and after a successful expedition advanced as far as the Atlantic. As early as 966 the plan of attempting a fresh invasion of Egypt was conceived, and preparations made for its execution; but it was delayed, it is said at the request of the caliph’s mother, who wished to make a pilgrimage to Mecca first; and her honourable treatment by Kāfūr when she passed through Egypt induced the caliph to postpone the invasion till that sovereign’s death.
In August 972 Mo‘izz resolved to follow Jauhar’s pressing invitation to enter his new capital Cairo. With his arrival there the centre of the Fatimite power was transferred from Mahdia and Kairawān to Egypt, and their original dominion became a province called al-Maghrib, which immediately fell into the hands of a hereditary dynasty, the Zeirids, acknowledging Fatimite suzerainty. The first sovereign was Bulukkīn, also called Abu’l-Futūḥ Yūsuf, appointed by Mo‘izz as his viceroy on the occasion of his departure for Egypt: separate prefects were appointed for Sicily and Tripoli; and at the first the minister of finance was to be an official independent of the governor of the Maghrib. On the death of Bulukkīn in 984 he was succeeded by a son who took the royal title al-Manṣūr, under whose rule an attempt was made by the Kutāma, instigated by the caliph, to shake off the yoke of the Zeirids, who originated from the Sanhaja tribe. This attempt was defeated by the energy of Manṣūr in 988; and the sovereignty of the Fatimites in the Maghrib became more and more confined to recognition in public prayer and on coins, and the payment of tribute and the giving of presents to the viziers at Cairo. The fourth ruler of the Zeirid dynasty, called Mo‘izz, endeavoured to substitute ‘Abbāsid suzerainty for Fatimite: his land was invaded by Arab colonies sent by the Fatimite caliph, with whom in 1051 Mo‘izz fought a decisive engagement, after which the dominion of the Zeirids was restricted to the territory adjoining Mahdia; a number of smaller kingdoms rising up around them. The Zeirids were finally overthrown by Roger II. of Sicily in 1148.
After the death of al-Ādid, the last Fatimite caliph in Egypt, some attempts were made to place on the throne a member of the family, and at one time there seemed a chance of the Assassins, who formed a branch of the Fatimite sect, assisting in this project. In 1174 a conspiracy for the restoration of the dynasty was organized by ‘Umarah of Yemen, a court poet, with the aid of eight officials of the government: it was discovered and those who were implicated were executed. Two persons claiming Fatimite descent took the royal titles al-Mo‘taṣim billah and al-Ḥāmid lillah in the years 1175 and 1176 respectively; and as late as 1192 we hear of pretenders in Egypt. Some members of the family are traceable till near the end of the 7th century of Islam.
The doctrines of the Fatimites as a sect, apart from their claim to the sovereignty in Islam, are little known, and we are not justified in identifying them with those of the Assassins, the Carmathians or the Druses, though all these sects are connected with them in origin. A famous account is given by Maqrīzī of a system of education by which the neophyte had doubts gently instilled into his mind till he was prepared to have the allegorical meaning of the Koran set before him, and to substitute some form of natural for revealed religion. In most accounts of the early days of the community it is stated that the permission of wine-drinking and licentiousness, and the community of wives and property formed part of its tenets. There is little in the recorded practice of the Fatimite state to confirm or justify these assertions; and they appear to have differed from orthodox Moslems rather in small details of ritual and law than in deep matters of doctrine.