Rural Spain emptied itself long ago through the rural exodus, a phenomenon that began after the industrial revolution, but which occurred with greater force, especially in the second half of the 20th century.
The rural exodus brought about the abandonment of the towns as people started looking for opportunities in the cities. This abandonment lead to the change of work, from activities very focused on the primary sector (agriculture), towards activities of the secondary sector (industry) or tertiary sector (services).
The towns gradually emptied, with an emigration to the cities of the province or to cities of other provinces. This occurred with special intensity in the most rural areas, which were not able to retain population. These towns have not been able to repopulate through new productive activities.
Nowadays, added to the drama of depopulation in the rural areas, is the fact that in most medium-sized cities (those that do not have enough industry to retain population) there is also an exodus to the big cities.
Thus, there are in Spain medium-sized cities that are gradually emptying out. Something like a second depopulation or exodus. For example, while big cities as Madrid grow and attracts talent and population, other medium-sized cities are emptying out.
In what is undoubtedly a global change, big cities tend to concentrate more and more population, while medium-sized cities tend to shrink. We find ourselves in a world of “mega-cities”, connected to each other by air or high-speed rail connections, in which what is in the middle matters less and less.