Spain is part of Europe.
The European Union ( EU ) is a political and economic union of member states that are located primarily in Europe . Madrid ( [ məˈdrɪd ] , [ maˈðɾið ] , [ maˈðɾi ] ) is the capital city of the Kingdom of Spain and the largest municipality in both the Community of Madrid and Spain as a whole . Spain ( España [ esˈpaɲa ] ) , officially the Kingdom of Spain ( [ Reino de España , links = no ] ) , is a sovereign state located on the Iberian Peninsula in southwestern Europe , with two large archipelagoes , the Balearic Islands in the Mediterranean Sea and the Canary Islands off the North African Atlantic coast , two cities Ceuta and Melilla in the North African mainland and several small islands in the Alboran Sea near the Moroccan coast . It is a member of the United Nations ( UN ) , the European Union ( EU ) , the Eurozone , the Council of Europe ( CoE ) , the Organization of Ibero-American States ( OEI ) , the North Atlantic Treaty Organization ( NATO ) , the Organisation for Economic Co-operation and Development ( OECD ) , the World Trade Organization ( WTO ) and many other international organisations .