Name of Monument:

Mahdiyya Kasbah


Mouth of the Wadi Sebu on the Atlantic coast 12 km from Kenitra, Mahdiyya, Morocco

Date of Monument:

Hegira 6th / AD 12th century; Hegira 11th / AD 17th century

Architect(s) / master-builder(s):

Ali ibn ‘Abdallah Errifi (master builder).

Period / Dynasty:

Almohad; Alawid


Almohad: ‘Abd al-Mu’min, AH 524–58 / AD 1130–1163; ‘Alawid: Mulay Isma‘il, AH 1083–1140 / AD 1672–1727.


The mouth of the Sebu, a navigable river that links the Atlantic to the rich Gharb plain and gives access to Fez and the interior of the country, was of major strategic importance in the Middle Ages, both militarily and commercially.
The first settlement (Marsa al-Ma'mora) was founded at this site in the AH 4th / AD 10th century, and in the AH 6th / AD 12th century, the Almohad king 'Abd al-Mu'min built his shipyard there, which used the excellent wood from the surrounding forests.
The small town of al-Ma'mora remained a trading centre with Europe until the AH 10th / AD 16th century.
In AH 921 / AD 1515, the Portuguese took the site, fortified it and named it Saint-Jean de la Mamoura, but their occupation lasted only 47 days.
In the AH 11th / AD 17th century, having been an important independent centre of piracy, al-Ma'mora was taken in AH 1022 / AD 1614 by the Spanish who built, on a rocky spur dominating the estuary, a fortress named San Miguel de Ultramar, the outer wall of which now forms most of the present day kasbah of Mahdiyya.
In AH 1091 / AD 1681, the 'Alawid Sultan Mulay Isma'il retook the site, which was then named Al-Mahdiyya (the submissive), and the name al-Ma'mora was henceforth only used to refer to the nearby forest.
Mulay Isma'il set up a genuine kasbah inside the fortress, with a house for the governor (Dar al-Makhzen), a mosque, barracks, a madrasa, a funduq, stables and silos.
The 'Alawid sovereign modified the Spanish wall by reinforcing the southern façade with bastions and deep ditches, although he kept the three towers on the north façade. He built a monumental gateway out of freestone in the wall, and its name, Bab Jdid (New Gateway) is inscribed in the band that frames the horseshoe arch entrance. This gateway is crowned by a gemeled window and is flanked by two massive protruding rectangular towers, topped with pyramidion crenelations. The gateway provides access to the kasbah via a bent corridor containing seats and a staircase that leads to the upper floors and a terrace that overlooks the estuary and the surrounding area.
The governor's house was a veritable palace, spacious and richly decorated. It is accessed through a finely decorated and carved stone gateway that leads through a courtyard and a covered passageway to the residence. Around a vast courtyard, whose polychrome zellij (small tiles) paving is still visible in places, four large rooms stand out for their poly-lobed horseshoe arches crowned with screen walls, which also have poly-lobed arches divided into three openings by two small columns.
The palace adjoined a garden and a hammam (baths) beyond which was the smaller house of the caid, remarkable for its finely worked door with sculpted lintels.
There is a circular building inside the kasbah that was used by the Spanish to store arms, and outside it there are some remains of a circular Spanish fort that overlooked the river, along with the remains of the large store houses built by Mulay Isma'il that extend for nearly 300 m on either side of the road.

View Short Description

In the AH 4th / AD 10th century, a settlement was founded at the mouth of the Sebu, a navigable river linking the Atlantic to the plains of the Gharb and Fez. Fitted out as a naval dockyard in the 6th / 12th century, it was taken in the 11th / 17th century by the Spanish, who erected a fortress.
In the 12th / 18th century, Mulay Isma'il set up a kasbah in the fortress, with a mosque, barracks, madrasa and a luxurious seigneurial residence, the remains of which include four large rooms around a zellij-paved courtyard, a garden and a hammam. He also constructed a monumental gateway flanked by two projecting towers in the wall.

How Monument was dated:

Ali ibn Abi-Zar mentions in Rawd al-Qirtas that 'Abd al-Mu'min gave the order in 557 / 1162 to fortify the entire coastline and start building 400 ships, 120 of which in Mahdiyya.

In Al-manbaa al-latif (History of Mulay Isma'ïl), Ibn Zaydan confirms that the sultan received the surrender of the Spanish garrison at Mahdiyya on 11 Rabi I 1092 (31 March 1681).

Selected bibliography:

Coindreau, R., La Casbah de Mehdya, Rabat, 1946.
Khatib-Boujibar, N : “La Kasbah de Mehdya”, Maisons du Maroc, no. 6, Casablanca, 1996.
Lévi-Provençal, É., “al-Mahdiya”, Encyclopédie de l'Islam, p.1236.
Marçais, G., L'architecture musulmane d'Occident, Paris, 1954, pp.409–10.
Montagne, R., “Note sur la Casbah de Mehdya”, Hespéris, 1921, pp.93–7.
Andalusian Morocco: A Discovery in Living Art, pp.208–10.

Citation of this web page:

Kamal Lakhdar "Mahdiyya Kasbah" in Discover Islamic Art, Museum With No Frontiers, 2020. 2020.;ISL;ma;Mon01;31;en

Prepared by: Kamal LakhdarKamal Lakhdar

Linguiste et sociologue de formation, c'est en autodidacte que Kamal Lakhdar s'est adonné aux études d'histoire du Maroc et du monde arabo-musulman, en axant tout spécialement ses recherches sur l'histoire de Rabat.
Sa carrière de haut fonctionnaire l'a conduit à occuper des fonctions de premier plan auprès de différents ministères. Il a notamment été membre du cabinet du ministre de l'Enseignement supérieur, conseiller du ministre des Finances, conseiller du ministre du Commerce et de l'Industrie, directeur de cabinet du ministre du Tourisme, chargé de mission auprès du Premier ministre et directeur de cabinet du Premier ministre.
Parallèlement, Kamal Lakhdar mène des activités de journaliste et d'artiste peintre – il a d'ailleurs été membre du Conseil supérieur de la Culture.

Copyedited by: Margot Cortez
Translation by: Laurence Nunny
Translation copyedited by: Monica Allen

MWNF Working Number: MO 40


Related monuments

 Artistic Introduction

 Timeline for this item

Islamic Dynasties / Period



On display in

Discover Islamic Art Exhibition(s)

The Muslim West | Defence


As PDF (including images) As Word (text only)