Spanish postal codes were introduced on 1 July 1984,
when the introduced automated mail sorting. They consist of five numerical digits,
where the first two digits, ranging 01 to 52, correspond either to one of the 50
provinces of Spain
A province in Spain
* , ; grammatical number, sing. ''provincia'')
* Basque language, Basque (, grammatical number, sing. ''probintzia''.
* Catalan language, Catalan (), grammatical number, sing. ''província''.
* Galician language, Galician ...
or to one of the two
autonomous cities on the African coast.
Two-digit prefixes

The first two digits of a Spanish postal code identify the province or autonomous city it belongs to. The numbers were assigned to the 50
provinces of Spain
A province in Spain
* , ; grammatical number, sing. ''provincia'')
* Basque language, Basque (, grammatical number, sing. ''probintzia''.
* Catalan language, Catalan (), grammatical number, sing. ''província''.
* Galician language, Galician ...
ordered alphabetically at the time of implementation.
The official names of some of the provinces have since changed, either to the regional language version of the name (e.g. from the Spanish to the Basque ) or to adopt the name of the autonomous community instead of the provincial capital (e.g. Santander to Cantabria). In these cases, the originally assigned code has been maintained, resulting in some exceptions to the alphabetical order. In addition, Ceuta and Melilla were originally included within the postal areas of Cádiz and Málaga respectively; in 1995 they were assigned their own codes and hence ended up at the end of the list.
The list below includes all 52 two-digit prefixes assigned to the 50 provinces and two autonomous cities. Included in brackets are the names of the provinces that were used for alphabetical sorting at the time of implementation, if different from the current name used in English.
* 01
Álava
* 02
Albacete
* 03
Alicante
* 04
Almería
* 05
Ávila
* 06
Badajoz
* 07
Balearic Islands ()
* 08
Barcelona
Barcelona ( ; ; ) is a city on the northeastern coast of Spain. It is the capital and largest city of the autonomous community of Catalonia, as well as the second-most populous municipality of Spain. With a population of 1.6 million within c ...
* 09
Burgos
* 10
Cáceres
* 11
Cádiz
* 12
Castellón
* 13
Ciudad Real
* 14
Córdoba
* 15
A Coruña ()
* 16
Cuenca
* 17
Girona ()
* 18
Granada
* 19
Guadalajara
* 20
Gipuzkoa ()
* 21
Huelva
* 22
Huesca
* 23
Jaén
* 24
León
* 25
Lleida ()
* 26
La Rioja ()
* 27
Lugo
* 28
Madrid
Madrid ( ; ) is the capital and List of largest cities in Spain, most populous municipality of Spain. It has almost 3.5 million inhabitants and a Madrid metropolitan area, metropolitan area population of approximately 7 million. It i ...
* 29
Málaga
Málaga (; ) is a Municipalities in Spain, municipality of Spain, capital of the Province of Málaga, in the Autonomous communities of Spain, autonomous community of Andalusia. With a population of 591,637 in 2024, it is the second-most populo ...
* 30
Murcia
* 31
Navarre ()
* 32
Ourense ()
* 33
Asturias ()
* 34
Palencia
* 35
Las Palmas ()
* 36
Pontevedra
Pontevedra (, ) is a city in the autonomous community of Galicia (Spain), Galicia, in northwestern Spain. It is the capital of both the ''Pontevedra (comarca), Comarca'' and Province of Pontevedra, and the capital of the Rías Baixas. It is als ...
* 37
Salamanca
* 38
Santa Cruz de Tenerife
* 39
Cantabria ()
* 40
Segovia
Segovia ( , , ) is a city in the autonomous communities of Spain, autonomous community of Castile and León, Spain. It is the capital and most populated municipality of the Province of Segovia. Segovia is located in the Meseta central, Inner Pl ...
* 41
Seville ()
* 42
Soria
* 43
Tarragona
* 44
Teruel
* 45
Toledo
* 46
Valencia
* 47
Valladolid
* 48
Biscay ()
* 49
Zamora
* 50
Zaragoza
* 51
Ceuta
Ceuta (, , ; ) is an Autonomous communities of Spain#Autonomous cities, autonomous city of Spain on the North African coast. Bordered by Morocco, it lies along the boundary between the Mediterranean Sea and the Atlantic Ocean. Ceuta is one of th ...
* 52
Melilla
Following digits
The third digit of a Spanish postal code is used to identify major cities or basic itineraries.
A zero denotes a provincial capital,
e.g. San Sebastián, as capital of the province of Gipuzkoa, uses the postal code 200xx.
The fourth and fifth digits are used to identify delivery areas, route itineraries or rural link itineraries.
Some codes are reserved for special use at the province capital:
* 070: official use by
Correos
* 071: to address state agencies at the given province
* 080: P.O. boxes and mail lists
References
External links
Find a postcode (Spanish post office website)Another postcode finder – displays results on a mapList of ZIP codes of Spanish municipalitiesSearch engine for postal codes in Spain
{{DEFAULTSORT:Postal codes in Spain
Spain
Spain, or the Kingdom of Spain, is a country in Southern Europe, Southern and Western Europe with territories in North Africa. Featuring the Punta de Tarifa, southernmost point of continental Europe, it is the largest country in Southern Eur ...
Postal system of Spain
Spain geography-related lists
Spain communications-related lists