The relationship between Spain and Morocco often centers around themes such as migration pressures, diplomatic crises, and territorial claims over Ceuta, Melilla, and the Canary Islands. In this arena, Rabat exhibits substantial leverage, as evidenced by its recent assertiveness at the border. However, it is crucial to note that Madrid holds a strategic position against its southern neighbor, fortified by two vital infrastructures that are integral to its energy system.
This paradox becomes glaringly evident when considering that the very nation that periodically questions Spain's sovereignty over Ceuta is entirely dependent on Spanish territory for its gas imports via pipeline. Moreover, Morocco's electricity system is interconnected with the continental European grid through submarine links to the Iberian Peninsula. This dependency was particularly highlighted in 2021 when Algeria decided not to renew the contract for the Maghreb-Europe Gas Pipeline (GME) after severing diplomatic relations with Rabat. Before this, Algerian gas would traverse Morocco en route to Spain. However, with the closure of the pipeline, the flow was reversed, and Spain began exporting gas to Morocco, sourcing it from the Medgaz pipeline and liquefied natural gas (LNG) via regasification plants.
Since then, the gas imported by Morocco through the GME has relied on a logistical chain anchored in Spain. In 2025, the Moroccan kingdom imported approximately 10.3 TWh of gas, accounting for about one in four megawatt-hours exported by the Spanish gas system that fiscal year, with a value nearing €400 million. This reliance illustrates the vulnerability that Morocco currently faces, which is also reflected in its own energy plans. Morocco is advancing a LNG terminal at Nador West Med to allow for direct maritime gas imports, aiming to connect with the old GME pipeline, thereby reducing its dependency on Spanish regasification plants. Additionally, the Nigeria-Morocco gas pipeline project is underway, but none of these alternatives will be able to replace the current supply framework in the short term. Until Morocco develops its own capacity to receive LNG, Spain will continue to hold an irreplaceable position in its gas supply chain.
Strategic Energy Interconnections
The second critical infrastructure is the electrical interconnection between Spain and Morocco, comprising two submarine cables linking Tarifa to the Moroccan coast, with a combined capacity of 1,400 megawatts (MW). This connection serves as more than just a commercial link; it is a vital integration point. According to Red Eléctrica, in 2025, Spain exported a net balance of 3,743 gigawatt-hours (GWh) of electricity to Morocco, marking a 47.5% increase over the previous year and the highest volume recorded since 2017. The flow of electricity shows a clearly dominant direction, with nearly three-quarters of the utilized capacity of the interconnection being electricity transported from the Iberian Peninsula to Morocco.
The significance of this connection transcends mere energy exchange volumes. It integrates the Moroccan system with the continental European electrical grid and provides additional capacity for exchange, backup, and operational flexibility, a function that is becoming increasingly important as Morocco ramps up its electricity demand, deploys new renewable generation, and develops large industrial hubs in the northern part of the country. Furthermore, Spain and Morocco are also exploring the construction of a third submarine cable to enhance exchange capacity and facilitate the integration of new renewable generation.
Isolated Cities and Strategic Security
The energy cooperation between these two nations embodies a particularly significant contradiction. While Spain has spent nearly three decades connecting Morocco energetically to Europe, Ceuta and Melilla have historically remained isolated from the Spanish electrical system. Ignacio Urbasos, a researcher at Global Affairs and Strategic Studies, highlights this disparity, stating, "The electrical integration between Spain and Morocco contrasts sharply with the energy isolation of the Spanish cities of Ceuta and Melilla." He further explains that Morocco has historically refused to supply electricity to these cities, which must operate as energy islands with two small fuel plants. However, the situation in Ceuta is on the brink of change, with a submarine cable set to connect the autonomous city to the peninsula in 2026, a project estimated to cost around €300 million. This infrastructure is expected to reduce the number of electrical incidents and bolster the security of supply in Ceuta, while Melilla, due to its geographical distance, is likely to remain isolated.
This comparison is hard to overlook. While Morocco has been connected to the European electrical system through Spain for almost three decades, Ceuta has had to wait until 2026 to secure its own link to the peninsula, with Melilla continuing to function as an energy island.
Over the years, these infrastructures have primarily been viewed through an economic lens. The deterioration of the geopolitical context has broadened this perspective, transforming energy networks into a matter of strategic security for states. That said, Spain cannot simply wield the gas pipeline or electrical interconnections as tools of political pressure. A deliberate disruption would carry significant legal, economic, and diplomatic repercussions. Nevertheless, these infrastructures are not geopolitically neutral; energy dependencies create vulnerabilities and, consequently, influence. While Morocco strives to mitigate this dependence, it currently lacks viable alternatives to replace it. As Rabat continues to assert its claims over Ceuta and Melilla, Spain remains the gateway for all gas that Morocco imports via pipeline, solidifying its role as a crucial player in the energy dynamics of the region.
As reported by elconfidencial.com.