The great Fatimid mosque of Mahdia was founded by Obeid Allah el Mahdi in 921. This building was erected on a platform partly reclaimed from the sea.
Located on the southern side of the peninsula on which the old city was located, the mosque was built in 916 CE (303-304 in the Islamic calendar), after the founding of the city within the walls built by the Caliphate on an artificial platform “reclaimed from the sea” as mentioned by the Andalusian geographer Al-Bakri.
The other buildings erected nearby at that time have since disappeared.
The original Fatimid mosque of Mahdi had two common walls with the maritime rampart of the medina. It should also be noted that this mosque was completely renovated, almost rebuilt, between 1961 and 1965, according to the exact plans of the tenth century sanctuary.
The monumental porch of the mosque was reserved for the entrances and exits of the Mahdi. The courtyard and the prayer hall were laid out by the Zirids in the eleventh century.
In the past, an aqueduct supplied water to the cisterns of the mosque and the Mahdi palace, of which only ruins remain.
Mahdia’s heritage is also the Borj el Kebir, a sixteenth-century fortress. It is also the Skifa kahla, the dark porch that marked the entrance to the old medina.
This enormous fortified city gate dates from 1554, after the departure of the Spaniards. It replaced the old Fatimid door of the tenth century.