# Muslim conquest of the Maghreb

The Muslim conquest of the Maghreb (Arabic: فَتْحُ اَلْمَغْرِب, romanized: Fath al-Maghrib, lit. 'Conquest of the West') or Arab conquest of North Africa by the Rashidun and Umayyad Caliphates commenced in 647 and concluded in 709, when the Byzantine Empire lost its last remaining strongholds to Caliph Al-Walid I. The North African campaigns were part of the century of rapid early Muslim conquests.
By 642 AD, under Caliph Umar, Arab Muslim forces had taken control of Mesopotamia (638 AD), Syria (641 AD), Egypt (642 AD), and had invaded Armenia (642 AD), all territories previously split between the warring Byzantine and Sasanian empires, and were concluding their conquest of Sasanian Persia with their defeat of the Persian army at the Battle of Nahāvand. It was at this point that Arab military expeditions into North African regions west of Egypt were first launched, continuing for years and furthering the spread of Islam.
In 644 at Medina, Umar was succeeded by Uthman, during whose twelve-year rule Armenia, Cyprus, and all of modern-day Iran, would be added to the expanding Rashidun Caliphate. With Afghanistan and North Africa being targets of major invasions and Muslim sea raids ranging from Rhodes to the southern coasts of the Iberian Peninsula, the Byzantine navy was defeated in the eastern Mediterranean.

## Sources for the history of the invasion

The earliest Arab accounts are those of ibn Abd al-Hakam, al-Baladhuri, and Khalifah ibn Khayyat, all of which were written in the ninth century, some 200 years after the first invasions. These are not very detailed. In the case of the most informative, the History of the Conquest of Egypt and North Africa and Spain by Ibn Abd al-Hakam, Robert Brunschvig has shown that it was written with a view to illustrating points of Maliki law rather than documenting history and that some of the events it describes are probably ahistorical.
Beginning in the 12th century, scholars at Kairouan began to construct a new version of the history of the conquest, which was finalised by Ibrahim ibn ar-Raqiq. This version was copied in its entirety and sometimes interpolated, by later authors, reaching its zenith in the 14th century by scholars such as ibn Idhari, ibn Khaldun and al-Nuwayri. It differs from the earlier version not only in greater detail but also in giving conflicting accounts of events. This, however, is the best-known version and is the one given below.

## First invasion

It is recorded by Ibn Abd al-Hakam that during the siege of Tripoli by Amr ibn al-As, seven of his soldiers from the clan of Madhlij, sub branch of Kinana, unintentionally found a section on the western side of Tripoli beach that was not walled during their hunting routine. These seven soldiers managed to infiltrate the city through this way without being detected by the city guards, and then managed to incite riots within the city while shouting Takbir (God is the greatest), causing the confused Byzantine garrison soldiers to think the Muslim forces were already inside in the city and to flee towards their ship leaving Tripoli, thus, allowing Amr to subdue the city easily.
Later, the Muslim forces besieged Barqa (Cyrenaica) for about three years to no avail. Then Khalid ibn al-Walid, who was previously involved in the conquest of Oxyrhynchus, offered a radical plan to erect catapult which filled by cotton sacks. Then as the night came and the city guard slept, Khalid ordered his best warriors such as Zubayr ibn al-Awwam, his son Abdullah, Abdul-Rahman ibn Abi Bakr, Fadl ibn Abbas, Abu Mas'ud al-Badri, and Abd al-Razzaq to step into the catapult platform which filled by cotton sacks. The catapult launched them one by one to the top of the wall and allowed these warriors to enter the city, opening the gates and killing the guards, thus allowing the Muslim forces to enter and capturing the city. Then caliph Umar, whose armies were already engaged in conquering the Sassanid Empire, did not want to commit his forces further in North Africa while Muslim rule in Egypt was still insecure and ordered 'Amr to consolidate the Muslims' position in Egypt and that there should be no further campaigning. 'Amr obeyed, abandoning Tripoli and Burqa and returning to Fustat towards the close of 643.
The next invasion of the Maghreb, ordered by Abdallah ibn Sa'd, commenced in 647. 20,000 soldiers marched from Medina in the Arabian Peninsula, with another joining them in Memphis, Egypt where Abdallah ibn Sa'd then led them into the Byzantine Africa, the Maghreb region. The invading army took Tripolitania (in present-day Libya). Count Gregory, the local Byzantine governor, had declared his independence from the Byzantine Empire in Africa. He gathered his allies, confronted the invading Islamic Arab forces and suffered defeat (647) at the Battle of Sufetula, a city 240 kilometres (150 mi) south of Carthage. With the death of Gregory, his successor, probably Gennadius, secured the Arab withdrawal in exchange for tribute. The campaign lasted fifteen months and Abdallah's force returned to Muslim territories in 648.
All further Muslim conquests were soon interrupted, however, when Egyptian dissidents murdered Caliph Uthman after holding him under house arrest in 656. He was replaced by Ali, who in turn was assassinated in 661. The Umayyad Caliphate of largely secular and hereditary Arab caliphs, then established itself at Damascus and Caliph Muawiyah I began consolidating the empire from the Aral Sea to the western border of Egypt. He put a governor in place in Egypt at al-Fustat, creating a subordinate seat of power that would continue for the next two centuries. He then continued the invasion of non-Muslim neighboring states, attacking Sicily and Anatolia (in Asia Minor) in 663. In 664, Kabul, Afghanistan, fell to the invading Muslim armies.

## Second invasion

The years 665 to 689 saw a new Arab invasion of North Africa. It began, according to Will Durant, to protect Egypt "from flank attack by Byzantine Cyrene". So "an army of more than 40,000 Muslims advanced through the desert to Barca, took it, and marched to the city of Carthage", defeating a defending Byzantine army of 20,000 in the process.
Next came a force of 10,000 Muslims led by the Arab general Uqba ibn Nafi and enlarged by thousands of others. Departing from Damascus, the army marched into Africa and took the vanguard. In 670, the city of Kairouan (roughly 150 kilometers [80 mi] south of modern Tunis) was established as a refuge and base for further operations. This would become the capital of the Islamic province of Ifriqiya (the Arabic pronunciation of Africa), which would be today's western Libya, Tunisia, and eastern Algeria.
After this, as Edward Gibbon writes, the fearless general "plunged into the heart of the country, traversed the wilderness in which his successors erected the splendid capitals of Fes and Morocco, and at length penetrated to the verge of the Atlantic and the great desert". In his conquest of the Maghreb (western North Africa), he besieged the coastal city of Bugia as well as Tingi or Tangier, overwhelming what had once been the traditional Roman province of Mauretania Tingitana.
But here he was stopped and partially repulsed. Luis Garcia de Valdeavellano writes:
   In their invasions against the Byzantines and the Berbers, the Arab chieftains had greatly extended their African dominions, and as early as the year 682 Uqba had reached the shores of the Atlantic, but he was unable to occupy Tangier, for he was forced to turn back toward the Atlas Mountains by a man who became known to history and legend as Count Julian.
Moreover, as Gibbon writes, Uqba, "this Mahometan Alexander, who sighed for new worlds, was unable to preserve his recent conquests. By the universal rebellion against muslim occupation of the Greeks and Africans he was recalled from the shores of the Atlantic." On his return, a Berber-Byzantine coalition under the berber king of Altava known as Kusaila ambushed and crushed his forces near Biskra, killing Uqba and wiping out his troops.
Then, adds Gibbon, "The third general or governor of Africa, Zuhayr, avenged and encountered the fate of his predecessor in the Battle of Mamma. He vanquished the native population in many battles but he was overthrown by a powerful army, which Constantinople had sent to the relief and liberation of Carthage."
Meanwhile, a new civil war among rivals for the monarchy raged in Arabia and Syria. It resulted in a series of four caliphs between the death of Mu'awiya in 680 and the accession of Abd al-Malik ibn Marwan in 685; strife ended only in 692 with the death of the rebel leader.

## Third invasion

This development brought about a return of domestic order that allowed the caliph to resume the Islamic conquest of North Africa. It began with the renewed invasion of Ifriqiya. Gibbon writes:
   the standard was delivered to Hassan governor of Egypt, and the revenue of that kingdom, with an army of forty thousand men, was consecrated to the important service. In the vicissitudes of war, the interior provinces had been alternately won and lost by the Saracens. But the seacoast still remained in the hands of the Greeks; the predecessors of Hassan had respected the name and fortifications of Carthage; and the number of its defenders was recruited by the fugitives of Cabes and Tripoli. The arms of Hassan were bolder and more fortunate: he reduced and pillaged the metropolis of Africa; and the mention of scaling-ladders may justify the suspicion, that he anticipated, by a sudden assault, the more tedious operations of a regular siege.
Having lost Carthage to the Muslims in 695, the Byzantine Empire responded with troops from Constantinople, joined by soldiers and ships from Sicily and a powerful contingent of Visigoths from Hispania. This forced the invading Arab army to run back to Kairouan. Then, writes Gibbon, “the Christians landed; the citizens hailed the ensign of the cross, and the winter was idly wasted in the dream of victory or deliverance.”
In 698, the Arabs conquered Carthage under Hassan ibn al-Nu'man and completed the conquest of the eastern Barbary coast. Anticipating attempts at Byzantine reconquest however, they decided to destroy it. The walls were torn down, the agricultural land ravaged, the aqueducts and harbors made unusable. They established their base instead at Tunis which was heavily expanded, though Kairouan remained the governor's capital until late-9th century.
This was immediately followed by a Berber rebellion against the new Arab overlords and a decisive victory at the Battle of Meskiana. Gibbon writes:
   Under the standard of their queen Kahina, the independent tribes acquired some degree of union and discipline; and as the Moors respected in their females the character of a prophetess, they attacked the invaders with an enthusiasm similar to their own. The veteran bands of Hassan were inadequate to the defence of Africa: the conquests of an age were lost in a single day; and the Arabian chief, overwhelmed by the torrent, retired to the confines of Egypt.
In 703, five years passed before Hassan received fresh troops from the caliph. Meanwhile, the people of North Africa's cities chafed under the Berber reign. Thus Hassan was welcomed upon his return, and managed to kill Kahina at the Battle of Tabarka. Gibbon writes that “the friends of civil society conspired against the savages of the land; and the royal prophetess was slain in the first battle.”
The successful general Musa bin Nusair was appointed the governor of Ifriqiya. His armies brutally put down the Berbers, consisting of various faiths, who fought against the advancing Muslims. Their conquest reached the Atlantic coast in 708. He was noted for the vast number of mawla he had amassed which consisted of Berber converts to Islam and people from other regions as well.
   In 698-702 AD all the major capitals in the Berber states were taken definitively by the Arabs: Christian Carthago was completely destroyed, half the inhabitants were killed (only a few hundreds could escape by boats toward Byzantine Sicily) and the rest enslaved, erasing forever the main center of Greco-Roman influence in the Maghreb. Musa bin Nusair, a successful Yemeni general in the campaign, was made governor of "Ifriqiya" and given the responsibility of putting down a renewed Berber rebellion and forcefully converting the population to Islam. Musa and his two sons prevailed over the rebels, slaughtered nearly all the Christian Berber civilians of his Ifriqiya and enslaved 300,000 captives (in those years the total population of the Maghreb was around one million, and this gives an idea of the massacre and why Christianity disappeared). The caliph's portion was 60,000 of the captives. He sold into slavery these Christian Berbers (mainly in Damascus, after a deadly deportation through the desert from southern Tunisia to Egypt): the proceeds from their sale went into the Arab public treasury.Daniel Pipes
The number of slaves he took in his various campaigns (including campaigns outside Africa, against the Romans and Persians) is said to range from 30,000 to 300,000 in various Muslim histories and some even allude to a higher number. Philip Khuri Hitti described the attribution of figures such as 300,000 slaves (also capturing 30,000 noble maidens of Spain) to him as exaggerated which was due to the high number of slaves that were available after Muslim conquests. An assertion which is confirmed by historian Kishori Saran Lal.
Musa also had to deal with the Byzantine navy that still fought on against the Muslim invasions. So he built a navy of his own which went on to conquer the Christian islands of Ibiza, Majorca, and Menorca. Advancing into the Maghreb, his forces took Algiers in 700.

## Aftermath

By 709, all of the top half of North Africa was under the control of the Arab caliphate. The only possible exception was Ceuta at the African Pillar of Hercules. Gibbon declares: "In that age, as well as in the present, the kings of Spain were possessed of the fortress of Ceuta [...] Musa, in the pride of victory, was repulsed from the walls of Ceuta, by the vigilance and courage of Count Julian, the general of the Goths." Other sources, however, maintain that Ceuta represented the last Byzantine outpost in Africa and that Julian, whom the Arabs called Ilyan, was an exarch or Byzantine governor. Valdeavellano offers another possibility, that "as appears more likely, he may have been a Berber who was the lord and master of the Catholic tribe of Gomera." In any case, being an able diplomat who was adept in Visigothic, Berber, and Arab politics, Julian might well have surrendered to Musa on terms that allowed him to retain his title and command. At this time the population of Ceuta included many refugees from a ruinous Visigothic civil war that had broken out in Hispania (modern Portugal and Spain). These included family and confederates of the late King Wittiza, Arian Christians fleeing forced conversions at the hands of the Visigothic Catholic church, and Jews.
As Gibbon puts it, Musa received an unexpected message from Julian, "who offered his place, his person, and his sword" to the Muslim leader in exchange for help in the civil war. Though Julian's "estates were ample, his followers bold and numerous", he "had little to hope and much to fear from the new reign." And he was too feeble to challenge Roderic directly. So he sought Musa's aid. For Musa, Julian, "by his Andalusian and Mauritanian commands, ... held in his hands the keys of the Spanish monarchy." And so Musa ordered some initial raids on the southern coast of the Iberian Peninsula in 710. In the spring of that same year, Tariq ibn Ziyad—a Berber, a freed slave, and a Muslim general—took Tangier. Musa thereupon made him governor there, backed by an army of 6,700. The next year, 711, Musa directed Tariq to invade Hispania. Disembarking from Ceuta aboard ships provided by Julian, Tariq plunged into the Iberian Peninsula, defeated Roderic, and went on to besiege the Visigothic capital of Toledo. He and his allies also took Córdoba, Ecija, Granada, Málaga, Seville, and other cities. Due to this, the Umayyad conquest of Hispania completed the Arab conquest of North Africa. Fearing that the Byzantine Empire might reconquer it, they decided to destroy Roman Carthage in a scorched earth policy and establish their headquarters somewhere else. Its walls were torn down, its water supply cut off, the agricultural land was ravaged and its harbors made unusable. The destruction of the Exarchate of Africa marked a permanent end to the Byzantine Empire's influence in the region.
It is visible from archaeological evidence, that the town of Carthage continued to be occupied. Constantine the African was born in Carthage. The fortress of Carthage was used by the Muslims until Hafsid era and was captured by the Crusaders during the Eighth Crusade. Remnants of former Roman Carthage was used as a source to provide building materials for Kairouan and Tunis in 8th century.

### Indigenous resistance

Although the area was under control of the caliphate, there were still some sections of the population that would resist the spread of Islam. The Berber people were thought of as inferior and made to convert to Islam and join the Arab army, receiving less pay than an Arab would have. This led to much dissatisfaction and ultimately the death of Maghreb Arab governor, Yazid ibn Abi Muslim at the hands of one of his bodyguards after ordering them to tattoo his name on their arms to signal his ownership.
In 740, a Berber Revolt was prompted by the taxation of the Berbers. The rebels were lead at first by Maysara, a Berber chieftain. It began in southern Morocco, lasting through to 743. The rebels managed to massacre the Arab population of Tangier, its Arab governor, and capture a territory including modern Morocco, Western and Central Algeria whom were never recovered by an Oriental caliphate, but failed to capture Ifriqiya (Tunisia, East-Algeria and West-Libya) after suffering a crushing defeat at the hand of Ifriqiya governor Handhala ibn Safwan al-Kalbi.
One of the unifying forces of these rebellions were the teachings of Arab Kharijite missionaries who had worked as merchants. They were able to convert some sections to their way of thinking and this provided a "unifying discipline and revolutionary zeal that powered the Berber rebellion of 739" through 743.

## Consequences
### Effects on the power structure in the Mediterranean region

The loss of Africa was a severe blow to the Byzantine Empire. In 698, after Egypt, the second large granary and a significant source of taxes went here was lost, which in retrospect did not detract from the empire's ability to survive, but significantly impaired the decades-long defensive struggles against the caliphate. Financially, the lost tax revenue for Eastern Rome/Byzantium could not be compensated for a long time.
The fall of Carthage brought Tiberios the imperial throne, for his officers, afraid of being held responsible for the defeat, elevated him to the position of anti-emperor and overthrew Leontios, who had his nose cut off. Another effect was that there were no longer any major Latin or Romance-speaking provinces in the Byzantine Empire and Greek finally prevailed.
With the conquest of Carthage, the Arabs laid the basis for domination of the western Mediterranean, since they could now use the African ports there as a springboard for operations against the Balearic Islands, Sardinia and Sicily. They also prepared for the invasion of Spain 13 years later by eliminating the flank threat. The capture of Septem, in turn, removed the last immediate obstacle.

### Islamization and partial Arabization of the Maghreb

On the territory of the Exarchate of Carthage, after the conquest, a rather gradual but ultimately complete Arabization of the Latin and Punic speaking population began. Contrary to widespread opinion, the Latin language did not disappear promptly or completely from the Maghreb, which can be read both from Latin grave inscriptions dating back to the eleventh century and from the numerous and conspicuous Latin foreign words in today's Berber languages on site. But the special features of the dialects of Maghrebi Arabic that developed after the conquest were also shaped primarily in the lexis of Latin. The same applies to Christianity in the Maghreb, which did not end with the Arab conquest, but is also documented afterwards by sporadic sources.
In what is now Tunisia, for example, Muslims were probably in the majority towards the end of the ninth century. The decline of Christian institutions only accelerated towards the end of the eleventh century; individual communities survived until the 14th century, after which trace of them was lost. The only thing that is certain is that at the beginning of French colonial rule in the Maghreb there were no longer any Romance-speaking or Christian communities. This ultimately complete Islamization of the entire population brought about the separation of the Mediterranean region into northern and southern halves, which continues to this day.
The full Islamization of the Maghreb along with the full Arabization of the non-Berber population may have been favored by the following factors:
* the still Neo-Punic and thus also Semitic mother tongue of parts of the population,
* possibly remaining Donatist ideas in Christian communities, whose martyristic and theocratic demands as well as rejection of Greco-Roman civilization were fulfilled by Islam,
* possibly remaining Arian ideas in Christian communities, whose anti-Trinitarian demands were fulfilled by Islam
* the fragmentation of the Church in Africa, which was also partly visible to the outside world
* Promotion of Arabization and Islamization given the exposed location of the Maghreb during the Spanish Reconquista and the conquests of the Norman ruler Roger II.

### Christianity after the conquest

Archaeological and scholarly research has shown that Christianity existed after the Muslim conquests. The Catholic church gradually declined along with local Latin dialect. According to a view, Christianity in North Africa effectively continued a century after the Muslim conquest but that neither the Church nor the ruling Byzantine veneer was able to resist the propagation of Islam, particularly since they were at odds with each other, and that without any particular persecution on the part of the Muslim rulers, who treated the Christians leniently because they were "People of the Book". Had the first Muslim conquerors persecuted the North African Christians rather than tolerating them, Christianity may well have continued to flourish.
Many causes have been seen as leading to the decline of Christianity in Maghreb. One of them is the constant warfare, as well as persecutions. In addition, many Christians migrated to Europe. The Church at that time lacked the backbone of a monastic tradition and was still suffering from the aftermath of heresies including the so-called Donatist heresy, and this contributed to the early obliteration of the Church in the present day Maghreb. Some historians contrast this with the strong monastic tradition in Coptic Egypt, which is credited as a factor that allowed the Coptic Church to remain the majority faith in that country until around after the 10th century despite numerous persecutions. In addition, the Romans were unable to completely assimilate the indigenous people like the Berbers.
Local Catholicism came under pressure when the Muslim fundamentalist regimes of the Almoravids and especially the Almohads came into power, and the record shows persecutions and demands made of the local Christians of Tunis to convert to Islam. Reports still exist of Christian inhabitants and a bishop in the city of Kairouan around 1150 – a significant report, since this city was founded by Arab Muslims around 680 as their administrative center after their conquest. A letter from the 14th century shows that there were still four bishoprics left in North Africa, admittedly a sharp decline from the more than four hundred bishoprics in existence at the time of the Arab conquest. The Almohad Abd al-Mu'min forced the Christians and Jews of Tunis to convert in 1159. Ibn Khaldun hinted at a native Christian community in 14th century in the villages of Nefzaoua, south-west of Tozeur. They paid the jizyah and had some people of Frankish descent among them. Berber Christians continued to live in Tunis and Nefzaoua in the south of Tunisia until the early 15th century, and "[i]n the first quarter of the fifteenth century, we even read that the native Christians of Tunis, though much assimilated, extended their church, perhaps because the last of the persecuted Christians from all over the Maghreb had gathered there."
Another group of Christians who came to North Africa after being deported from Islamic Spain were called the Mozarabs. They were recognised as forming the Moroccan Church by Pope Innocent IV.
Another phase of Christianity in Africa began with the arrival of the Portuguese in the 15th century. After the end of Reconquista, the Christian Portuguese and Spanish captured many ports in North Africa.
In June 1225, Honorius III issued the bull Vineae Domini custodes, which permitted two friars of the Dominican Order, named Dominic and Martin, to establish a mission in Morocco and look after the affairs of Christians there. The Bishop of Morocco, Lope Fernandez de Ain, was made the head of the Church of Africa, the only church officially allowed to preach in the continent, on 19 December 1246 by Pope Innocent IV. Innocent IV asked the emirs of Tunis, Ceuta and Bugia to permit Lope and Franciscian friars to look after the Christians in those regions. He thanked Caliph al-Sa'id for granting protection to the Christians and requested to allow them to create fortresses along the shores, but the Caliph rejected that request.
The bishopric of Marrakesh continued to exist until the late 16th century and was borne by the suffragans of Seville. Juan de Prado had attempted to re-establish the mission but was killed in 1631. Franciscan monasteries continued to exist in the city until the 18th century.