In 1920, the Spanish seized Chefchaouen to form part of Spanish Morocco. Spanish troops imprisoned Abd el-Krim in the kasbah from 1916 to 1917, after he talked with the German consul Dr. Walter Zechlin (1879–1962). (After defeating him with the help of the French, Abd el-Krim was deported to Réunion in 1926.) Spain returned the city after the independence of Morocco in 1956.
Chefchaouen or Chaouen, as it is often called by Moroccans, is a popular tourist destination because of its proximity to Tangier and the Spanish enclave of Ceuta. The name refers to the shape of the mountain tops above the town, that look like the two horns (chaoua) of a goat. "Chef Chaouen" derives from the Berber word for horns, Ichawen. There are approximately two hundred hotels catering to the summer influx of European tourists. One distinction possessed by Chefchaouen is its blue-rinsed houses and buildings.