The Christians led by Alonso Pérez de Guzmán (1256–1309) entered the town in 1303 after the moor, who have settled in Southern Spain since the 8th Century, had deserted it. Guzman claimed these territories for the crown of Castille, and his possessions in Southern Spain eventually led to the foundation of the dukedom of Medina-Sidonia. The Battle of Barrosa, a French defeat by the Anglo-Spanish army, took place south of Chiclana on 5 March 1811. During the Spanish War of Independence came the Battle of Chiclana, which took place in the town between the French and an Anglo-Spanish alliance. In 1900, tenders were invited by the municipal authorities, Le Secretariat del Ayuntamienti de Chiclana de la Frontera, for an electric lighting concession of the town. In the early 20th century, seasonal Algarvian migration brought workers to Chiclana's cereal fields. Sancti Petri was visited in 1930 by Manuel de Falla, seeking inspiration.