Russia–Spain relations

The Russian Federation and the Kingdom of Spain, a member state of the European Union, have bilateral foreign relations. Spain and the Grand Duchy of Moscow first exchanged envoys in 1520s; regular embassies were established in 1722. The two countries share a long history of relations, characterized at times by close cooperation and at other times by deep hostility. Soviet-Spanish relations, once terminated after the Spanish Civil War, were gradually reestablished starting in 1963 and were fully established by 1977. Trade between the two countries amounted to two billion euros in 2008. In March 2009, the two countries signed an energy agreement providing national energy companies access to other party's domestic markets.

Muscovy and Imperial Russia
Official contacts between the Spanish Empire and the Grand Duchy of Moscow go back to 1519, when King Charles I of Spain notified Grand Duke Vasili III of Russia of his ascension to the throne of the Holy Roman Empire. In 1523, Yakov Polushkin delivered Vasili's response to the court at Valladolid, thus becoming the first Russian envoy to Spain. In 1525 Russian envoys Ivan Zasekin-Yaroslavsky and Semyon Borisov presented their credentials to Charles; they brought news of the discovery of the Americas to Muscovy.

The Spanish Inquisition and especially the aftermath of the Alhambra Decree expelling Jews from the Kingdom were of particular interest to 16th-century Russian Orthodox clergy who had the interest to suppress the Judaizers heresy within the Russian Orthodox Church. Muscovy, unlike contemporary European nations, studied the Inquisition not "as an example to avoid but a model to imitate".

Another temporary contact was established by Pyotr Potemkin's embassy (1667–1668) during the reign of Alexis I of Russia.

Regular embassies of the two countries were established by Peter I of Russia and Philip V of Spain in 1722; in 1723, the Russian Empire also opened a consulate in Cádiz. Prince Sergey Golitsyn served as the first Russian ambassador to Spain; duke Diego Francisco de Liria, who also inherited the Jacobite title of Duke of Berwick, served as ambassador of Spain in Russia. However, after the unexpected death of Peter II of Russia, Spain declared the ascension of Anna of Russia unlawful and severed diplomatic relations until 1759. De Liria, who closely watched the events of 1730, provided an important account of Anna's ascension.

In 1799–1801 Spain severed ties after Paul I of Russia assumed the Catholic title of Grand Master of Knights Hospitaller; in 1833–1856 Russia closed the embassies, denying legitimacy of Isabella II of Spain. Apart from these two conflicts, relationships were uneventful; the two countries were never engaged in direct war against each other. In 1756–1763 they were allies in the Seven Years' War. During the Napoleonic Wars the two countries were both allies and foes, but never engaged each other directly.

While Russian intelligentsia commented favorably regarding colonial rebels during the decolonization of the Americas, Tsar Alexander I (1777-1825) supported the efforts to suppress rebellion by Spain's King Ferdinand VII (1784-1833). Plans for sales of warships were kept secret to avoid British interference. In August 1817, Russia sold the Spanish Navy five ships of the line and three frigates. They were delivered to Cádiz in February 1818. Russia ignored the independent Latin American states until the late 19th century.

In 1893, Director of Police Pyotr Nikolayevich Durnovo caused a minor diplomatic incident by ordering secret agents to steal correspondence between the Spanish Ambassador and his mistress, a prostitute whom Durnovo had become smitten with. The crisis ended when the ambassador complained to Tsar Alexander III, who dismissed Durnovo.

During the Russian Revolution, Alfonso XIII attempted the exfiltration of the Romanov family from Russia to Spain after the abdication of Nicholas II. Interestingly, Grand Duchess Maria Vladimirovna was born in Madrid on December 23, 1953 and, currently, she lives in the Spanish capital with her son George Mikhailovich Romanov, who was born on March 13, 1981. 

Soviet period
The Soviet Union established diplomatic relations with the Second Spanish Republic on July 28, 1933. Moscow for years tried to purify the Spanish Communist Party by expelling anarchist and Trotskyite members, but the process took years and was finally handled by outside Communists sent to Spain in the Spanish Civil War who exposed and executed opponents. Ambassador Marsel Rosenberg (1896–1938), his adviser and successor Leon Gaikis (1898–1937), and Consul-general Vladimir Antonov-Ovseenko (1883–1938) arrived in Madrid in 1936, when Spanish Civil War was already underway. The three were soon recalled to Moscow and executed for an alleged Trotskist conspiracy.

The Soviet Union actively supported the Republican faction through the course of the Civil War with military advisers, "volunteers" and weapons supplied in exchange for Bank of Spain gold reserves later known as Moscow gold (see Foreign involvement in the Spanish Civil War). The monument to Soviet volunteers in Madrid, inaugurated in 1989 by mayor Juan Barranco Gallardo and Soviet ambassador Sergey Romanovsky, lists 182 names of identified Soviet combatants killed during the war. With the fall of Republicans and the victory of the Nationalists in 1939, the Soviet Union lost all ties with Spain, now under Franco. During World War II the Blue Division of Spanish volunteers in the Wehrmacht fought against the Soviet Red Army on the Eastern Front until Francisco Franco removed them. Franco steered away from direct participation in the war and maintained Spain's neutrality.

Spain's relations with the Soviets after World War II were described as "the worst, though hardly the most problematic", culminating in Nikita Khrushchev's speech against Franco's regime in the United Nations General Assembly on October 1, 1960 and Franco's ban on the Spain vs. USSR game of the 1960 European Nations' Cup scheduled earlier in the same year. Soon, however, the same leaders began gradual reestablishment of contacts. In April 1963 Khrushchev and Franco exchanged letters on disarmament and the fate of Julián Grimau; in January 1964 Franco appealed to Khrushchev again. According to Soviet explanation of events, the move was initiated by the Spanish government.

Until 1969, relations were informally maintained through Soviet and Spanish embassies in France. In 1967 Spanish and Soviet representatives agreed to open their seaports to ships carrying flag of the other country; in 1969 the Soviet state-owned Black Sea Shipping Company opened an office in Madrid – the first Soviet establishment in Spain since the Civil War. This office, staffed by professional diplomats, and headed by Sergey Bogomolov, who relocated to Madrid from Paris, doubled as the de facto Soviet consulate.

The two countries signed an agreement on foreign trade in 1972. It promoted amicable diplomatic relations and the strategic partnership between the two countries. They established permanent trading missions in 1973; these offices assumed and maintained consular duties. Igor Ivanov, future foreign minister of independent Russia, has served in Madrid in 1973–1983. After Franco's death, the Soviet Union and Spain reestablished full diplomatic relations on February 9, 1977. Bogomolov assumed the title of Soviet ambassador and presented his credentials to king Juan Carlos I of Spain on May 5, 1977. Relations of this period were not exactly friendly, marred with mutual expulsion of alleged spies operating under diplomatic immunity; things got worse when Spain was admitted into NATO in 1981, an act regarded by the USSR as a "violation of Soviet interests".

After Bogomolov moved up to a senior position in the Ministry of Foreign Affairs in 1978, he was replaced by Yuri Dubinin, who steered Soviet policy in Spain through the last phase of the Cold War, until 1986. Dubinin actively promoted the idea of a state visit by Juan Carlos to Moscow; only after five years of preparations did Andrei Gromyko approve the visit that materialized in May 1984. Alexander Igorevich Kuznetsov, former (2005 to 2012) Russian ambassador to Spain and Andorra, has served in Madrid under Dubinin in 1982–1986.

The Embassy of Russia in Madrid, inherited from the Soviet Union, was built in 1986–1991. The land lot at 155, Calle de Velázquez, was provided to the Soviets in 1980, but was loaded with zoning regulations limiting building height to 6 meters, presence of Spanish Armed Forces cables running underground and a gypsy squat town sprawling above – these obstacles held off construction for years. The building was initially designed by painter Ilya Glazunov; Glazunov later contributed interior design, building structure was redesigned by architect Anatoly Polikarpov.

1991-2021
Spain and post-Communist Russia established diplomatic relations on December 9, 1991. This resulted in improved economic, trade, and cultural relations. There were museum exhibition exchanges and several visits between the two countries' leaders including Prime Minister Vladimir Putin, Russian President Dmitry Medvedev, and Spanish King Juan Carlos I. They dealt with the issue of Kosovo's independence from Serbia, Spain's chairmanship of the European Union (EU) in 2010, and foreign energy policy. Igor Ivanov, a veteran of the Soviet embassy in Madrid, was appointed Ambassador of Russia to Spain and served in Madrid until 1994. In April 1994 president Boris Yeltsin became the first Russian head of state to pay a state visit to Spain. Juan Carlos visited Russia in 2002, 2006, 2008 and 2012.

Spain's share in Russian foreign trade in early 2000s hovered at just above 1% of Russian exports (dominated by oil and raw materials); Spanish exports to Russia were significantly lower (2001: 488 million US dollars vs. 890 million). In 2008, according to Dmitry Medvedev, foreign trade levelled at 2 billion Euro (less than 1% of either country's foreign trade) while that between Russia and other countries comparable to Spain is measured in tens of billion euro. Spain's share in foreign direct investment to Russian economy remains insignificant, the largest investment (as at 2003), at 319 million US dollars, has been made by Segura Consulting.

In December 2000 the relations were strained by Spain' refusal to extradite fugitive banker and media executive Vladimir Gusinsky. Gusinsky, arrested and released in Spain, emigrated to Israel in April 2001.

During the most recent state visit of Russian president Dmitry Medvedev to Spain, in March 2009, two countries signed an energy agreement giving Spanish companies greater access to Russian fossil fuels in exchange to easing Spanish regulations regarding purchase of Spanish energy companies by Russian businesses. According to Spanish Prime Minister José Luis Rodríguez Zapatero, "The memorandum means greater security in Spain's energy supplies and it guarantees better access for our companies to Russian energy reserves". The memorandum was followed by an agreement between Gazprom and Gas Natural that gives the Spanish side access to Gazprom's export pipelines and, potentially, Shtokman gas field output, in exchange for a stake in Spanish electric utilities.

In 2016, the Spanish Secretary of State for Foreign Affairs, Ignacio Ybanez, told NATO officials Spain's support for constructive relations and cooperation between Russia and NATO, so the country defends the continuation of the political dialogue, said the Spanish Ministry of Foreign Affairs.

In 2019, Spain and Russia regained their cooperation, deteriorated by economic and political tides. Of this, many evidence was recently provided, ranging from the inauguration at the Pushkin Museum in Moscow, of an exhibition of works by Pablo Picasso to the agreement to create an alliance between eight public universities in the two countries. Relations deteriorate in the short term when in May the Spanish Foreign Minister Josep Borrell in interview to Spanish newspaper El Periodico de Catalunya called Russia "old enemy" of Europe. Moscow, believing that he was referring to an unfriendly statement between Spain and Russia, cited the Spanish ambassador to Russia, Fernando Valderrama Pareja, to express the disappointment of Borrell's words. The Spanish minister himself said his statements were misunderstood. Vladimir Putin declared that "it is a new nonsense, the alleged threat from Russia to Spain, which is in another part of the European continent" and stressed that the Russians love Spain and wish it prosperity and all the best. He also added that "as you know, the Soviet Union welcomed thousands of Spanish children, most stayed in our country," he recalled, and "I have good relations with King Emeritus Juan Carlos I and now King Felipe VI," Putin stressed. The Spanish monarch, Felipe VI, launching a Europeanist message in the face of the European Parliament elections held in May, defended Russia's "key" role for economic prosperity. The deputy governor of Moscow Oblast, Vadim Jromov, said, in exclusive statements to The Diplomat, that there are several areas of cooperation between Russia and Spain “very broadly favorable to both” and "we consider that the business world has nothing to do with sanctions and we will continue to support friendly relations between Spain and Russia, which are already hundreds of years old and are not going to be changed by particular decisions taken at any given time”. The Minister Counselor of the Embassy of the Russian Federation in Spain, Dmitry Sokolov, classified the relations between Spain and Russia as excellent and declared that “we don't mess with the internal politics of Spain. The differences and internal disputes of any country must be resolved based on the Constitution, laws and dialogue between the political forces”. Both countries celebrated 300 years of diplomatic and cultural relations that led to the inauguration of permanent embassies in 1723, recalling that "500 years ago the first official contacts between the Spanish court and the Muscovite Duchy took place."

In 2020, the representative of Russian diplomacy said in the margins of the 11th edition of the Gaidar Forum to ignore whether contacts have already been established between Moscow and the new Spanish Government, and assured that Russia is interested in "deepening the traditional friendly relations and of association "with Spain. "We believe that there is no reason for our nations to be guided by the politics of others and we trust that Russian-Spanish relations, with the current Government - or with any other - have a good future," he said. The Russian ambassador in Madrid, Yuri Korchagin, assured Efe that relations between Spain and Russia have been "excellent" with both the People's Party government and now with the Spanish Socialist Workers' Party. "Never, with democratic governments in Spain, have we had any problems or any impasse. There is always an interest in moving forward, promoting our relationship and friendship. Relations between Russia and Spain are friendly," he said. He also declared: "If Spain had a more active or proactive role in re-establishing bridges (between the EU and Russia), it would play a historic role that would benefit everyone." 

Spain, along with rest of the European Union (EU) member states, positioned against Russia during the 2020–2021 Belarusian protests and for the arrest of opposition leader Alexei Navalny. 

2022-present
After the 2022 Russian invasion of Ukraine started, Spain, as one of the EU member states, imposed sanctions on Russia, and Russia added all EU countries to the list of "unfriendly nations". In light of the EU sanctions, Spanish authorities started to impound a number of superyachts believed to belong to Russian oligarchs. On 5 April 2022, the Spanish foreign minister announced the expulsion of 25 Russian diplomats and embassy staff, deemed to "represent a threat to the security of our country" (Spain).

However, on July 11, 2022, news broke that Spain's purchase of Russian gas had increased, making Russia the second largest supplier of gas to Spain, only behind the United States. This is due, according to the Minister of Ecological Transition, Teresa Ribera, to "prior agreements" to the invasion of Ukraine. Russia thus surpassed Algeria in the ranking of the largest gas suppliers to Spain, due to the diplomatic crisis that Algeria and Spain are suffering, which caused a collapse of Algerian gas imports, after Spain changed its position to a pro-Morocco position regarding the Western Sahara conflict.

Trade
In 2021 Spain exported $2.76 billion worth of goods to Russia with clothing being the main item. Russia exported $5.54 billion of goods with refined oil as the top product. Between 1995 and 2021 Spanish exports have risen by an average of 7.94% p.a. whilst Russian exports have risen by 5.77% on average.

August 2023 saw Spain export €66.2m and import €93.2 million in the month showing a large fall in trade and a closing of the trade gap.

Resident diplomatic missions

 * Russia has an embassy in Madrid and a consulate-general in Barcelona.
 * Spain has an embassy in Moscow and a consulate-general in Saint Petersburg.