Spain is a country.
Mediterranean Sea . The countries with coastlines on the Mediterranean Sea are Albania , Algeria , Bosnia and Herzegovina , Croatia , Cyprus , Egypt , France , Greece , Israel , Italy , Lebanon , Libya , Malta , Morocco , Monaco , Montenegro , Slovenia , Spain , Syria , Tunisia and Turkey . 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 . Its mainland is bordered to the south and east by the Mediterranean Sea except for a small land boundary with Gibraltar ; to the north and northeast by France , Andorra , and the Bay of Biscay ; and to the west and northwest by Portugal and the Atlantic Ocean . It is the only European country to have a border with an African country ( Morocco ) and its African territory accounts for nearly 5 % of its population , mostly in the Canary Islands but also in Ceuta and Melilla .