When Spanish tercios (military corps) concentrated in Roussillon at the end of the 1630s, because of the Thirty Years' War with France, the local peasants were required to lodge and provision the troops.
Finally, on 17 January 1641, the General Estates declared the Catalan Republic under the protection of France, but a week later the Catalan institutions, needing more French military aid, accepted the King Louis XIII of France as Count of Barcelona.