The most used code is ".es" (from España). There are too the code ".cat" used by some pages from the autonomous community of Catalonia.
If you sre asking for the country code to make an international telephone call the country code is 34.
The country code and area code of Asturias, Spain is 34, 884.
The country code and area code of Alava, Spain is 34, 845.
The country code and area code of Badajoz, Spain is 34, 824.
The country code and area code of Gerona, Spain is 34, 872.
The country code and area code of Cuenca, Spain is 34, 869.
The country code and area code of Vizcaya, Spain is 34, 846.
The country code and area code of Toledo, Spain is 34, 825.
The country code and area code of Barcelona, Spain is 34, 830.
The country code and area code of Albacete, Spain is 34, 867.
The country code and area code of AlmerÌ_a, Spain is 34, 850.
The country code and area code of Caceres, Spain is 34, 827.
The country code and area code of Cantabria, Spain is 34, 842.