Historically, Hungary (as part of the Austro-Hungarian Empire) and Spain were both ruled by the House of Habsburg for a few centuries. As such, both empires were allies in several wars such as the Thirty Years' War and the Ottoman–Habsburg wars. In October 1918, the Kingdom of Hungary became independent after the Dissolution of Austria-Hungary.
During the Spanish Civil War, over 1,000 Hungarian volunteers fought for the Republican faction. The Hungarian volunteers had their own battalion known as the Rakosi Battalion. In February 1938 Hungary, led by Miklós Horthy, officially recognized the government of Francisco Franco.
In 1945, soon after the end World War II, Spain broke diplomatic relations with Hungary after that nation became a communist country. In January 1977, both nations re-established diplomatic relations.
Both nations have signed several bilateral agreements such as a Judicial Settlement and Arbitration Treaty (1929); Air Transport Agreement (1974); Agreement on Commercial Exchanges, Navigation, Transport and the Development of Economic, Industrial and Technical Cooperation (1976); Agreement for Scientific and Technical Cooperation (1979); Cultural and Scientific Cooperation Agreement (1982); Tourism Cooperation Agreement (1982); Consular Agreement (1982); Agreement to Avoid Double Taxation and Prevent Tax Evasion in matters of Income and Wealth Taxes (1984); Agreement on Reciprocal Enforcement of Judicial Resolutions in criminal matters (1987); Agreement on Mutual Recognition of Certificates and Academic Titles (1989); Agreement for the Promotion and Reciprocal Protection of Investments (1989); and a Treaty of Friendship and Cooperation (1992).
Resident diplomatic missions
- Hungary has an embassy in Madrid and a consulate-general in Barcelona.
- Spain has an embassy in Budapest.
- Hungarian Studies Review
- Los vaivenes de las relaciones húngaro-españolas (1938-1977)
- Hungría y España conmemoran 40 años de restablecimiento de relaciones (in Spanish)
- MAEC: Hungría (in Spanish)
- Embassy of Hungary in Madrid
- Embassy of Spain in Budapest