The Kasbah or Agadir Oufella (the upper town of Agadir) was built in 1540 by Sultan Mehmed Sheikh al-Saadi to protect the city from possible invasions, especially Portuguese. Portuguese who had settled at the foot of the mountain since 1470 AD as part of their search for India. To build the Kasbah on top of the same peak.