The Battle of Larache occurred on February 7, 1631, when the forces of Sidi M'hamed el-Ayachi ambushed a detachment of the Spanish garrison of Larache.

Background On January 27, 1605, during a civil war in Morocco, the Moroccan sultan, Mohammed esh Sheikh el Mamun, was defeated by his brother, Zidan Abu Maali. Mohammed took refuge in Spain afterward. There he signed a treaty with Philip III of Spain, whereby he obtained military support in return for ceding the northern Moroccan port of Larache.Jehanne-Marie Gandin (1970), La remise de Larache aux Espagnols en 1610, p. 72 At the time of the expulsion of Morsicos from Spain, Sidi al-Ayachi rose in fame, devouring himself to launch a holy war against the Christians.Henry de Castries, p. 189 In April 1627, Sidi al-Ayachi revolted against the sultan and attacked the harbor of Salé, which he captured and transformed into his principality, the Republic of Salé, becoming its independent governor.Kenneth R. Andrews, Ships, Money and Politics: Seafaring and Naval Enterprise in the Reign of Charles I, p. 167 al-Ayachi began attacking the Spanish areas in Morocco. In Larache, he managed to capture a spy named Ibn Aboud. Al-Ayachi ordered his execution, but Ibn Aboud begged for support in exchange for his life.Mohammed al-Ifrani, p. 442-443

Battle al-Ayachi then dispatched Ibn Aboud to Larache to lure the Spanish out of town. Ibn Aboud reported that a group of Arab tribes were camping on a hill close to the town, and a potential attack would result in a large amount of loot. The Spanish immediately left the town.Mohammed al-Ifrani, p. 442-443 Diego Ruiz de ColmenaresTomás García Figueras & Carlos Rodríguez Joulia Saint, p. 177 led the Spanish troops of around 600 men.Henry de Castries, p. 195 The troops of al-Ayachi surrounded the Spanish troops and massacred them.Mohammed al-Ifrani, p. 443 Diego was wounded in the battle and died later on. The Spanish troops suffered 436 casualties,Tomás García Figueras & Carlos Rodríguez Joulia Saint, p. 177 or the entire force was killed.Henry de Castries, p. 195 The ambush took place on February 7, 1631.Henry de Castries, p. 195

References

Sources Henry de Castries (1911), Unpublished sources of Moroccan history. Archives and libraries of France. Volume III. Mohammed al-Ifrani, History of the Saadian dynasty in Morocco: 1511–1670. Tomás García Figueras & Carlos Rodríguez Joulia Saint-Cyr (1973), Larache: datos para su historia en el siglo XVII.