Municipalities of Spain by active companies

Madrid had the highest active companies of 6895 municipalities in 2018, at 312,285. Zael had the lowest, at 4. The median was 47 and the figure for Spain was 3.34 million. Source: the Instituto Nacional de Estadística.

Keep it in a collection in your library.
Highest312,285Madrid
Lowest4Zael
Median476895 municipalities
Spain3,337,646History

Top 40 municipalities, 2018

Madrid: 312,285 countMadrid312,285Barcelona: 182,986 countBarcelona182,986València: 65,068 countValència65,068Sevilla: 49,707 countSevilla49,707Zaragoza: 46,442 countZaragoza46,442Málaga: 41,022 countMálaga41,022Palma: 36,883 countPalma36,883Murcia: 33,722 countMurcia33,722Las Palmas de Gran Canaria: 28,472 countLas Palmas de Gran Canaria28,472Bilbao: 26,672 countBilbao26,672Alacant/Alicante: 26,042 countAlacant/Alicante26,042Vigo: 23,446 countVigo23,446Córdoba: 21,507 countCórdoba21,507A Coruña: 21,154 countA Coruña21,154Valladolid: 19,837 countValladolid19,837Granada: 19,113 countGranada19,113Marbella: 18,301 countMarbella18,301Gijón: 17,866 countGijón17,866Elx/Elche: 17,016 countElx/Elche17,016Oviedo: 16,196 countOviedo16,196Santa Cruz de Tenerife: 16,176 countSanta Cruz de Tenerife16,176Donostia/San Sebastián: 16,125 countDonostia/San Sebastián16,125Terrassa: 14,746 countTerrassa14,746Sabadell: 14,496 countSabadell14,496Pamplona/Iruña: 14,295 countPamplona/Iruña14,295Vitoria-Gasteiz: 14,164 countVitoria-Gasteiz14,164Badalona: 13,399 countBadalona13,399L'Hospitalet de Llobregat: 13,308 countL'Hospitalet de Llobregat13,308Burgos: 13,110 countBurgos13,110Castelló de la Plana/Castellón de la Plana: 12,648 countCastelló de la Plana/Castellón de…12,648Albacete: 12,367 countAlbacete12,367Almería: 12,313 countAlmería12,313Santander: 11,715 countSantander11,715Cartagena: 11,500 countCartagena11,500Logroño: 11,495 countLogroño11,495Las Rozas de Madrid: 11,435 countLas Rozas de Madrid11,435Pozuelo de Alarcón: 11,087 countPozuelo de Alarcón11,087Jerez de la Frontera: 11,025 countJerez de la Frontera11,025Fuenlabrada: 10,926 countFuenlabrada10,926Alcobendas: 10,903 countAlcobendas10,903Madrid: 312,285 countMadrid312,285Barcelona: 182,986 countBarcelona182,986València: 65,068 countValència65,068Sevilla: 49,707 countSevilla49,707Zaragoza: 46,442 countZaragoza46,442Málaga: 41,022 countMálaga41,022Palma: 36,883 countPalma36,883Murcia: 33,722 countMurcia33,722Las Palmas de Gran Canaria: 28,472 countLas Palmas de Gran Canaria28,472Bilbao: 26,672 countBilbao26,672Alacant/Alicante: 26,042 countAlacant/Alicante26,042Vigo: 23,446 countVigo23,446Córdoba: 21,507 countCórdoba21,507A Coruña: 21,154 countA Coruña21,154Valladolid: 19,837 countValladolid19,837Granada: 19,113 countGranada19,113Marbella: 18,301 countMarbella18,301Gijón: 17,866 countGijón17,866Elx/Elche: 17,016 countElx/Elche17,016Oviedo: 16,196 countOviedo16,196Santa Cruz de Tenerife: 16,176 countSanta Cruz de Tenerife16,176Donostia/San Sebastián: 16,125 countDonostia/San Sebastián16,125Terrassa: 14,746 countTerrassa14,746Sabadell: 14,496 countSabadell14,496Pamplona/Iruña: 14,295 countPamplona/Iruña14,295Vitoria-Gasteiz: 14,164 countVitoria-Gasteiz14,164Badalona: 13,399 countBadalona13,399L'Hospitalet de Llobregat: 13,308 countL'Hospitalet de Llobregat13,308Burgos: 13,110 countBurgos13,110Castelló de la Plana/Castellón de la Plana: 12,648 countCastelló de la Plana/Castellón de la Plana12,648Albacete: 12,367 countAlbacete12,367Almería: 12,313 countAlmería12,313Santander: 11,715 countSantander11,715Cartagena: 11,500 countCartagena11,500Logroño: 11,495 countLogroño11,495Las Rozas de Madrid: 11,435 countLas Rozas de Madrid11,435Pozuelo de Alarcón: 11,087 countPozuelo de Alarcón11,087Jerez de la Frontera: 11,025 countJerez de la Frontera11,025Fuenlabrada: 10,926 countFuenlabrada10,926Alcobendas: 10,903 countAlcobendas10,903
count. Source: INE, Directorio central de empresas: empresas activas por municipio (tabla 4721). Retrieved 2026-10-12.

Full ranking

RankMunicipalities2018
count
Change on 2017
1Madrid312,285+2.6%
2Barcelona182,986+2.5%
3València65,068+2.5%
4Sevilla49,707+1.5%
5Zaragoza46,442+1%
6Málaga41,022+2.3%
7Palma36,883+3.9%
8Murcia33,722+2.5%
9Las Palmas de Gran Canaria28,472+2.9%
10Bilbao26,672+2.3%
11Alacant/Alicante26,042+2.5%
12Vigo23,446+1.5%
13Córdoba21,507+0.4%
14A Coruña21,154+1.3%
15Valladolid19,837-0%
16Granada19,113+0.9%
17Marbella18,301+4.7%
18Gijón17,866+0.7%
19Elx/Elche17,016+2.9%
20Oviedo16,196+0.9%
21Santa Cruz de Tenerife16,176+2%
22Donostia/San Sebastián16,125+2%
23Terrassa14,746+0.5%
24Sabadell14,496+0.8%
25Pamplona/Iruña14,295+0.7%
26Vitoria-Gasteiz14,164+3.7%
27Badalona13,399+3.2%
28L'Hospitalet de Llobregat13,308+3.4%
29Burgos13,110+1.1%
30Castelló de la Plana/Castellón de la Plana12,648+0.3%
31Albacete12,367-0.6%
32Almería12,313+1.4%
33Santander11,715-0.2%
34Cartagena11,500+2.2%
35Logroño11,495+0.7%
36Las Rozas de Madrid11,435+0.4%
37Pozuelo de Alarcón11,087+0.8%
38Jerez de la Frontera11,025+0.9%
39Fuenlabrada10,926+1.5%
40Alcobendas10,903+4.7%
41Lleida10,836-0.1%
42Badajoz10,396+2.5%
43Sant Cugat del Vallès10,376+2.6%
44Salamanca10,179+0.5%
45Móstoles9,811+1%
46Leganés9,632+1.1%
47San Cristóbal de La Laguna9,622+3.2%
48León9,580+1.2%
49Alcalá de Henares9,524+2%
50Girona9,473+2%
51Santiago de Compostela9,411+1.9%
52Mataró9,406+1.8%
53Ourense9,311+0.5%
54Getafe9,285+2.4%
55Alcorcón9,021+2.1%
56Lugo8,756+1.5%
57Tarragona8,359-1%
58Huelva7,573+1.7%
59San Sebastián de los Reyes7,302+2.7%
60Jaén7,233+0.5%
61Cáceres7,118+1.6%
62Dos Hermanas7,080+1.4%
63Reus7,057+1.2%
64Arona6,913+4.6%
65Majadahonda6,903+1.5%
66Pontevedra6,635+0.6%
67Fuengirola6,465+3.4%
68Mijas6,387+6.1%
69Torrejón de Ardoz6,296+2.3%
70Rivas-Vaciamadrid6,170+3.5%
71Cádiz6,117+1.9%
72Torrevieja5,851+5%
73Lorca5,845-0.2%
74Toledo5,821+1.7%
75Getxo5,818+3.9%
76Paterna5,777+2.2%
77Boadilla del Monte5,747+4.1%
78Orihuela5,650+4.6%
79Algeciras5,635-0.4%
80San Bartolomé de Tirajana5,614+2.7%
81Roquetas de Mar5,593+2.4%
82Eivissa5,575+6.5%
83Telde5,520+1.8%
84Benidorm5,511+2.5%
85Manresa5,507-0.2%
86Estepona5,501+2.8%
87Castelldefels5,485+3%
88Cornellà de Llobregat5,419+2.6%
89Ponferrada5,371+0.1%
90Benalmádena5,356+5.7%
91Granollers5,350+2%
92Vélez-Málaga5,323+1.5%
93Ciudad Real5,212+1.3%
94Talavera de la Reina5,165+0.2%
95Santa Coloma de Gramenet5,132+1.3%
96Palencia5,113-0%
97El Puerto de Santa María5,096+0.3%
98Torremolinos5,089+1.7%
99Gandia5,059+2.4%
100Adeje5,038+7.4%
101Calvià5,029+3.2%
102Molina de Segura4,977+3.6%
103El Ejido4,974+2.2%
104Rubí4,969+0.5%
105Parla4,911+4.4%
106Coslada4,876+1.4%
107Barakaldo4,855+5.5%
108Zamora4,798-0.5%
109Torrent4,764+1%
110Alcalá de Guadaíra4,742-0.3%
111Sant Boi de Llobregat4,737+0.2%
112Melilla4,667+3.2%
113Vilanova i la Geltrú4,660+2.5%
114Irun4,607+4.2%
115Guadalajara4,570-0%
116Chiclana de la Frontera4,497+0.7%
117Dénia4,378+2.6%
118Mérida4,337+2.7%
119Cerdanyola del Vallès4,270+0.8%
120Arrecife4,258+3.9%
121Avilés4,2250%
122Valdemoro4,179+2%
123Siero4,123-0.6%
124Arganda del Rey4,094+3.1%
125Huesca4,066-0%
126Vic3,990-0.2%
127Collado Villalba3,940+2.2%
128Ceuta3,916+1.9%
129Elda3,908-0.4%
130Viladecans3,907+0.5%
131Alcoi/Alcoy3,817+0.1%
132Cuenca3,779+0.7%
133Ferrol3,759+0.6%
134Figueres3,736+0.3%
135Ávila3,709+0.5%
136Sant Vicent del Raspeig/San Vicente del Raspeig3,627+0.8%
137Segovia3,614+0.8%
138Mairena del Aljarafe3,511+2.6%
139Esplugues de Llobregat3,504+2.3%
140Tres Cantos3,486+2.3%
141Sagunt/Sagunto3,484-1.2%
142Igualada3,469+1.1%
143El Prat de Llobregat3,440-2.4%
144Manacor3,423+2.3%
145Gavà3,409+1.4%
146Villaviciosa de Odón3,348-0.6%
147San Fernando3,337+1%
148Santa Lucía de Tirajana3,311+3.9%
149Motril3,300+0.4%
150Sitges3,248+2.3%
151Vila-real3,229+0.3%
152Santa Eulària des Riu3,216+5.2%
153Sanlúcar de Barrameda3,165+0.7%
154Pinto3,161+3.9%
155Torrelavega3,1130%
156Puerto del Rosario3,104+5.2%
157Granadilla de Abona3,030+6.8%
158Colmenar Viejo3,015+2.3%
159Rincón de la Victoria3,004+3.9%
160Vilafranca del Penedès2,939+1.2%
161Xàbia/Jávea2,931+4.3%
162Plasencia2,930+2%
163Oleiros2,887+2.9%
164Alzira2,875+1.9%
164Lucena2,875+1.4%
166Sant Feliu de Llobregat2,860+1.3%
167Aranjuez2,826+0.4%
168Ontinyent2,819-0.9%
169Marratxí2,796+2.9%
170Llucmajor2,777+1.5%
171Soria2,774-0.3%
172San Fernando de Henares2,761+2.5%
173Mollet del Vallès2,760+1.3%
174Lloret de Mar2,757+1.4%
175Montcada i Reixac2,722+1.7%
176Linares2,689+0.9%
177Cambrils2,669+2.2%
178Alhaurín de la Torre2,650+2.6%
179Teruel2,647-0.8%
180Carballo2,646+1%
181Yecla2,632+0.2%
182Puerto de la Cruz2,625+2.4%
183Barberà del Vallès2,621+1.6%
184Tudela2,619-0.9%
185Vilagarcía de Arousa2,594+1.2%
186Galapagar2,577+4.7%
187La Línea de la Concepción2,522-0.3%
188Alcantarilla2,514+0.7%
189Utrera2,503+2%
190Almendralejo2,498+2.8%
191Tomelloso2,492+1.3%
192La Orotava2,475+2.1%
193Torrelodones2,458+3.3%
194Torre-Pacheco2,457+1.1%
195Don Benito2,453+1.1%
195Maó2,453+2.6%
197Ciutadella de Menorca2,444+2.6%
198Olot2,423+1.9%
199Arteixo2,409+1.9%
200Petrer2,382-0.3%
201Antequera2,379-0.5%
202Blanes2,372-1.2%
203Basauri2,355+3%
204Écija2,350-0.7%
205Úbeda2,348+1.1%
206El Vendrell2,342+2.8%
207Sant Joan Despí2,340+0.8%
208Altea2,324+0.8%
209Ames2,301+2.8%
210Ripollet2,296+0.6%
211Tortosa2,285-0.4%
212Ronda2,257+1.6%
213Arroyomolinos2,250+2.6%
213Sant Pere de Ribes2,250+1%
215Narón2,245+1.2%
216Aranda de Duero2,2430%
217Tías2,239+4.5%
218Villena2,232+2.3%
219Villarrobledo2,218-0.9%
220Humanes de Madrid2,206+1.2%
221La Oliva2,203+2%
222Culleredo2,191+1.2%
223Villanueva de la Cañada2,185+4%
224Portugalete2,173-0.2%
225Andújar2,167+1.4%
226Sant Just Desvern2,1640%
227La Rinconada2,159-1.5%
228Camargo2,138-0.1%
229Vinaròs2,134-0.4%
230Xàtiva2,128-0.5%
231Inca2,123+6.3%
231San Javier2,123+1.6%
233Crevillent2,121+2.4%
234El Masnou2,117+1%
235Los Realejos2,110+1.4%
235Sant Adrià de Besòs2,110+2.3%
235Santa Pola2,110+5.1%
238Molins de Rei2,094+0.9%
239Castro-Urdiales2,092+1.1%
239Riba-roja de Túria2,092+2.8%
241Santurtzi2,078+2.6%
242Mislata2,071+0.2%
243Illescas2,060+4.5%
244el Campello2,054+2.4%
245Leioa2,053+1.5%
246Langreo2,044+0.5%
247Sant Quirze del Vallès2,042+2.4%
248Errenteria2,038+1.3%
249Santa Perpètua de Mogoda2,035+0.3%
250Castellar del Vallès2,033-0.1%

Showing the top 250 of 6895. The Excel download has every row.

Other periods

About this ranking

Active companies on 1 January (INE Central Business Directory, DIRCE).

Every value in the ranking comes from the same publisher and the same period, so the municipalities are compared on one definition. 464 municipalities with data in other periods have no value for 2018 and are left out rather than filled from another source. Equal values share a rank.

How to cite

Instituto Nacional de Estadística (INE). Directorio central de empresas: empresas activas por municipio (tabla 4721). https://www.ine.es/jaxiT3/Tabla.htm?t=4721. Retrieved 2026-10-12.

Citation styles

The publisher is the author. Invokely is named only as the place the figures were read, where a style asks for it.

APA 7

Instituto Nacional de Estadística. (2026). Directorio central de empresas: empresas activas por municipio (tabla 4721) (Municipalities of Spain by active companies, 2018) [Data set]. Retrieved October 12, 2026, from https://www.ine.es/jaxiT3/Tabla.htm?t=4721

MLA 9

Directorio central de empresas: empresas activas por municipio (tabla 4721), Municipalities of Spain by active companies, 2018. Instituto Nacional de Estadística, 7 Oct. 2026, https://www.ine.es/jaxiT3/Tabla.htm?t=4721. Invokely, https://invokely.ai/rankings/active-companies/spain-municipalities?period=2018. Accessed 12 Oct. 2026.

Chicago (author-date)

Instituto Nacional de Estadística. 2026. Directorio central de empresas: empresas activas por municipio (tabla 4721). Municipalities of Spain by active companies, 2018. Dataset. Accessed October 12, 2026. https://www.ine.es/jaxiT3/Tabla.htm?t=4721. Also distributed by Invokely, https://invokely.ai/rankings/active-companies/spain-municipalities?period=2018.

Harvard

Instituto Nacional de Estadística (2026) Directorio central de empresas: empresas activas por municipio (tabla 4721), Municipalities of Spain by active companies, 2018 [Dataset]. Available at: https://www.ine.es/jaxiT3/Tabla.htm?t=4721, via Invokely: https://invokely.ai/rankings/active-companies/spain-municipalities?period=2018 (Accessed: 12 October 2026).

BibTeX
@misc{instituto_municipalities_of_spain_by_2018,
  author = {{Instituto Nacional de Estadística}},
  title = {{Directorio central de empresas: empresas activas por municipio (tabla 4721): Municipalities of Spain by active companies, 2018}},
  year = {2026},
  howpublished = {Data set},
  url = {https://www.ine.es/jaxiT3/Tabla.htm?t=4721},
  urldate = {2026-10-12},
  note = {Accessed via Invokely, https://invokely.ai/rankings/active-companies/spain-municipalities?period=2018. Publisher attribution: Instituto Nacional de Estadística (INE). Directorio central de empresas: empresas activas por municipio (tabla 4721). https://www.ine.es/jaxiT3/Tabla.htm?t=4721. Retrieved 2026-10-12.},
}
RIS
TY  - DATA
AU  - Instituto Nacional de Estadística
TI  - Directorio central de empresas: empresas activas por municipio (tabla 4721): Municipalities of Spain by active companies, 2018
PY  - 2026
DA  - 2026/10/07
PB  - Instituto Nacional de Estadística
DB  - Invokely
UR  - https://www.ine.es/jaxiT3/Tabla.htm?t=4721
L2  - https://invokely.ai/rankings/active-companies/spain-municipalities?period=2018
Y2  - 2026/10/12
N1  - Accessed via Invokely, https://invokely.ai/rankings/active-companies/spain-municipalities?period=2018.
N1  - Publisher attribution: Instituto Nacional de Estadística (INE). Directorio central de empresas: empresas activas por municipio (tabla 4721). https://www.ine.es/jaxiT3/Tabla.htm?t=4721. Retrieved 2026-10-12.
ER  - 
Embed this chart

Paste this code into a web page or a blog post. The chart shows the latest figures as they are published, with the source and a link back to this page.

Sites that read oEmbed links, such as WordPress, can show the chart when you paste the link to this page.

Use this data in your AI agent

Invokely serves this figure to AI assistants through MCP and to code through a REST API, with the source and citation attached. Ask your assistant:

Rank Municipalities of Spain by active companies using official data, and cite the source.
rank_places {"indicator":"active_companies","level":"municipality","within":"Spain","limit":10}
GET https://invokely.ai/api/v1/rank?indicator=active_companies&level=municipality&within=Spain&limit=10

Connect Claude, ChatGPT or Cursor in one step. The trial answers 25 calls a day without an account.

Questions

Which municipality has the highest active companies?

Madrid, with 312,285 in 2018, according to the Instituto Nacional de Estadística.

Which municipality has the lowest active companies?

Zael, with 4 in 2018.

Where does this ranking come from?

Every value comes from one source and one period, so the places are comparable: Instituto Nacional de Estadística, Directorio central de empresas: empresas activas por municipio (tabla 4721). Retrieved 2026-10-12. 464 municipalities have no value for 2018 and are not ranked.

Active companies: other rankings

Municipalities of Spain: more rankings