Portugal–Spain border disputed between the two countries for two hundred years. A microstate existed previously on the border called Couto Misto. Districts on the Portuguese side of the border from North to South: Provinces on the Spanish side of the border from North to South: Portugal and Spain signed the Schengen Agreement in June 1991 which came into effect on 26 March 1995, making Portugal and Spain part of the Schengen area and thus the border then became an Open border. Portugal has since reintroduced border checks several times along the border with Spain, during the UEFA Euro 2004 championships, during the
Portugal I of Portugal signed with the king Fernando IV of Castile (which was represented, when being a minor, by his mother the queen Maria de Molina) the Treaty of Alcañices (1297), which stipulated that Portugal abolished agreed treaties against the kingdom of Castile for supporting the infant Juan de Castilla. This treaty established inter alia the border demarcation between the kingdom of Portugal and the kingdom of Leon, where the disputed town of Olivenza was included. The reigns of Dinis I (Denis I), Afonso IV (Alphons IV), and Pedro I (Peter I) for the most part saw peace with the