Marrakesh

The red city of southern Morocco, founded by the Almoravids about 1070 and capital of the Almohad caliphate from 1147 to 1269, where the Koutoubia Mosque was built and Muhammad al-Nasir died after Las Navas de Tolosa.

Overview

Marrakesh lies on the Haouz plain of southern Morocco, north of the High Atlas, where water brought from the mountains made an oasis in dry country. The Almoravids founded it about 1070 as the capital of an empire that ran from the western Sahara to the Ebro valley, and from 1147 the Almohads made it the seat of a caliphate ruling the Maghreb and al-Andalus. Medieval Europeans called the city Maroch or Marrochio and named the whole country after it.

Its surviving medieval fabric is Almoravid and Almohad: the rammed-earth walls of the 1120s, the small domed Almoravid Qubba, the Koutoubia Mosque and the kasbah gate of Bab Agnaou. After the Marinids moved the capital to Fez in 1269 Marrakesh became a restless provincial city, and it regained its rank only under the Saadians in the sixteenth century.

Foundation

The Almoravids were a movement of Sanhaja Berber tribes of the western Sahara, united from the 1040s by the preacher Abd Allah ibn Yasin around a strict reading of Maliki law. In 1058 they took Aghmat, the market town at the foot of the Atlas. Its crowded streets did not suit a camp of desert tribesmen, and their emir Abu Bakr ibn Umar chose open ground about 30 kilometres away, on the boundary between two local tribes.

The chroniclers disagree on the date: Ibn Abi Zar and Ibn Khaldun place the foundation about 1062, while Ibn Idhari gives 1070. A common reconciliation dates the tent camp to the 1060s and the first stone fort, the Qasr al-Hajar, to 1070. Abu Bakr returned to the Sahara in 1071 and left the camp to his cousin Yusuf ibn Tashfin, who built its first mosque and made it the base from which he conquered Morocco.

Almoravid capital, 1070–1147

From Marrakesh Yusuf ibn Tashfin crossed to al-Andalus at the call of its taifa kings, defeated Alfonso VI at the Battle of Sagrajas in 1086, and between 1090 and 1094 deposed those same kings and annexed their states. The poet-king al-Mutamid of Seville was sent into captivity at Aghmat, where he died in 1095. By 1092 gold dinars were being struck in Marrakesh.

Yusuf's son Ali ibn Yusuf, who ruled from 1106 to 1142, turned the camp into a city. He built a palace, the great mosque later called Ben Youssef, founded in 1126, public fountains and khettaras, underground channels bringing water from the Atlas foothills. For the mosque he ordered a carved wooden minbar from Córdoba, begun in 1137, which survives in the Badi Palace. As the Almohad threat grew in the mountains, he enclosed the city with walls of rammed earth in the 1120s.

The Almohad caliphs, 1147–1269

The Almohads followed Ibn Tumart, a Masmuda preacher who proclaimed himself the Mahdi in 1121, made Tinmel in the High Atlas his base and denounced the Almoravids as heretics. Their first assault on Marrakesh failed in 1130, when the Almoravids routed them in the orchards east of the city. Under Ibn Tumart's successor Abd al-Mumin they conquered the rest of Morocco, besieged the capital for about eleven months and stormed it in April 1147, killing the last Almoravid ruler, the young Ishaq ibn Ali.

Abd al-Mumin declared that the Almoravid mosques faced the wrong way, abandoned or pulled them down, and built a new Friday mosque beside the old Almoravid fortress. It was soon rebuilt on a slightly different alignment, and the second Koutoubia Mosque, named after the booksellers' market beside it, was in use by 1158. Its minaret was probably largely built under Abd al-Mumin and finished under Yaqub al-Mansur, and it was the model for the minaret of the Great Mosque of Seville, now the Giralda.

Yaqub al-Mansur, caliph from 1184 to 1199 and victor over Alfonso VIII of Castile at the Battle of Alarcos in 1195, built a royal citadel, the kasbah, south of the medina, entered by the carved stone gate of Bab Agnaou and served by its own mosque, completed in 1190. The chronicler Abd al-Wahid al-Marrakushi described the hospital he founded, with gardens and running water.

After the Battle of Las Navas de Tolosa in 1212, Muhammad al-Nasir withdrew to Marrakesh and died there the next year, and the caliphate tore itself apart. In the late 1220s Idris al-Mamun crossed from Seville with Castilian mercenaries, took Marrakesh by force, massacred the Almohad sheikhs and publicly rejected Ibn Tumart's claim to be the Mahdi. The Marinids, advancing from the north, took the city in September 1269.

Marinid provincial city, 1269–1525

The Marinid sultans ruled from Fez and governed Marrakesh as the capital of the south, often through a prince of the ruling family. The Ben Salah mosque was completed in 1331 and Abu al-Hasan founded a madrasa in the 1340s, but the city shrank. Ibn Battuta, who passed through in the mid-fourteenth century, admired its mosques and the Koutoubia minaret but found much of Marrakesh in ruins.

Its governors rebelled against Fez in 1288, 1307 and 1320, and after about 1430 the Hintata chiefs of the High Atlas ruled the city as a virtually independent emirate. In 1515 a Portuguese army and its Moroccan allies advanced from the coast to the outskirts and were driven off with the help of the Saadian sharifs, who took Marrakesh in 1525 and made it a royal capital again.

Rulers and notable figures

Four rulers built medieval Marrakesh: Yusuf ibn Tashfin made it a capital, Ali ibn Yusuf gave it walls, water and a great mosque, Abd al-Mumin conquered it and built the Koutoubia, and Yaqub al-Mansur added the kasbah. Their court drew scholars from al-Andalus. Ibn Tufayl, physician to the caliph Abu Yaqub Yusuf and author of the philosophical tale Hayy ibn Yaqzan, introduced Ibn Rushd to the caliph and died in Marrakesh in 1185. Ibn Rushd, known in Latin Europe as Averroes, served the Almohads as physician and judge and died in Marrakesh in 1198.

Qadi Iyad, the leading Maliki jurist of the Almoravid age, died in 1149 and is buried in Marrakesh, as is the Sufi Abu al-Abbas al-Sabti, famous for preaching charity, who died in 1204 and became the patron saint of the city. In January 1220 five Franciscan friars who had preached in Marrakesh were executed there; their relics, taken to Coimbra, moved the young canon who became Saint Anthony of Padua to join their order.