Spain’s borders are far more bizarre and intricate than a simple glance at the map suggests. While it appears to have just two land neighbors—France to the north and Portugal to the west—Spain actually shares land borders with five countries, including some truly unexpected ones. These quirks stem from history, treaties, colonial legacies, and clever diplomatic solutions. Let’s explore why Spain might just have the strangest borders in Europe.
Llívia: The Spanish Town Trapped in France
One of the most famous oddities is Llívia, a small Catalan town of about 1,500 people that’s completely surrounded by French territory. Located in the Pyrenees just a couple of kilometres from the main border, Llívia is a classic enclave—Spanish soil entirely encircled by France.
This anomaly dates back to the Treaty of the Pyrenees in 1659, which ended a war between France and Spain. The treaty ceded certain “villages” in the Cerdanya region to France, but Llívia was classified as a “town” (due to its historical city rights), so it stayed Spanish. Today, it’s an exclave connected to the rest of Spain by a narrow road corridor through French land. Residents cross an invisible border daily, and the town maintains its Spanish identity amid French surroundings.
Pheasant Island: The Island That Switches Countries Twice a Year
Even stranger is Pheasant Island (Île des Faisans in French, Isla de los Faisanes in Spanish), a tiny, uninhabited river island in the Bidasoa River marking part of the France-Spain border near Hendaye and Irun.
After the same 1659 Treaty of the Pyrenees, neither side could agree on dividing it—so they created the world’s smallest condominium with alternating sovereignty. From February 1 to July 31, it’s under Spanish control; from August 1 to January 31, it becomes French. A ceremonial handover occurs every six months, though the island is closed to the public and has been this way for over 350 years, making it one of the longest-lasting such arrangements in history.
Andorra: The Tiny Hidden Neighbour
Nestled high in the Pyrenees between Spain and France lies Andorra, one of Europe’s smallest countries. With a population of around 80,000 and an area roughly half the size of New York City, this microstate is an independent principality co-ruled symbolically by the French president and the Bishop of Urgell in Spain.
Andorra shares a 57 km border with France to the north and east, and a 64 km border with Spain to the south and west. It’s easy to overlook on a map, but it’s a fully sovereign neighbour tucked away in the mountains.
Gibraltar: The British Outpost on Spanish Soil
Spain’s most contentious neighbour is the United Kingdom, thanks to Gibraltar—a British Overseas Territory at the southern tip of the Iberian Peninsula. Captured by Britain in 1713 during the War of the Spanish Succession, Gibraltar controls the northern side of the Strait of Gibraltar, a vital chokepoint between the Atlantic and Mediterranean.
Spain has long disputed British sovereignty, but the 6.8 km² rocky outcrop remains UK territory, creating a land border between Spain and the UK despite the distance between the two countries.
Africa’s Edge: Spain’s Borders with Morocco
Perhaps the most surprising twist: Spain is the only European country with a land border on the African continent, thanks to its enclaves along the Moroccan coast.
- Ceuta and Melilla are autonomous Spanish cities on the North African mainland, functioning as EU outposts in Africa. Both are heavily fortified and points of migration pressure.
- The third is Peñón de Vélez de la Gomera, a small rocky peninsula that was once an island but became connected to Morocco by a sandy isthmus over time.
This connection forms the world’s shortest international land border—just 85 meters long. Morocco claims these territories, but Spain administers them as integral parts of its sovereign land.
Why These Borders Feel So Strange
Spain’s map hides layers of history: medieval treaties, colonial holdovers, and pragmatic compromises. From a town classified as too important to cede, to an island that politely alternates ownership, to African enclaves bridging continents—these aren’t just lines on a map. They’re living relics of centuries of negotiation, rivalry, and ingenuity.
Next time you look at Spain on a globe, remember: its neighbours aren’t just France and Portugal. They’re a whole collection of hidden, disputed, and delightfully weird ones.


