Mahdia is a quiet seaside town on a narrow peninsula between Sousse and Sfax, and you would hardly guess it was once the capital of Tunisia. Proclaimed capital in 921 by the Fatimid caliphs, it spent centuries at the centre of power struggles between the Caliph of Cairo and local rulers, was repeatedly attacked by Genoese navies and Sicilian troops, and later became a headquarters for the corsair Dragut before facing off against Spanish and Maltese knights.
The entrance to the medina is through an enormous sixteenth-century gate, the Skifa Kahla. Inside, the narrow streets lead to the remains of ancient ramparts and a fortress, the Cape Africa lighthouse, and a beautiful sailors' cemetery overlooking the sea. The central mosque, dating from the tenth century, is a striking austere building. Beyond the old town, Mahdia today belongs to its fishermen mending their nets on the harbour and the silk weavers of Rue Sidi Jaber. A few kilometres south, a string of beaches stretches along the coast — some of the finest sand in Tunisia.