The absence of a strong industrial base led to emigration to colonies in South America, which alleviated the pressures of population growth, but post-WW1 tighter immigration controls meant more rural-urban migration and a consequent rise in housing
The CatholicChurch and the army were very influential in Spain, with the Church almost always supporting the interests of the wealthier classes, leading to resentment from poorer Spaniards
The army was too large and expensive for Spain's diminished world role, with a top-heavy officer corps that was impossible to reduce or reform as it employed mainly the upper and middle classes and symbolised former greatness
The army tradition of officers and generals taking political initiatives and inaugurating coups meant the army still had the power to create and destroy governments
Spain's late industrial development led to a small middle class, with the wealthier commercial and industrial classes identifying with the landed class, while the professional men, small business owners, and shopkeepers were more radical
The CNT, the Anarchist trade union, was supported by workers in Catalonia and peasants in Andalusia, and unlike most European countries at the time, Spain had a strong Anarchist presence
The 'Tragic Week' in the summer of 1909 saw many killed in a spate of rioting and church burning caused by the calling up of reservists for the Moroccan War
Spain's political system from 1898 to 1923 was a constitutional monarchy, with the King having some prerogatives, but power mainly lying with parliament
Universal male suffrage was introduced in the 1880s, but the system was more akin to an oligarchy than a genuine democracy, with the 'Caciquismo' system of elections controlled by local notables through intimidation, ballot rigging, and patronage
Most governments were a coalition or permutation of the two main interest groups (conservatives and liberals), leading to a system that bred cynicism, apathy, and disillusionment among Spaniards
Catalonia and the Basque Country expressed dissatisfaction with the central government through the rise of separatist movements demanding self-governance
Spain's loss of most of its colonies in South America, such as Cuba and the Philippines, during the war with the US, led to it becoming a third-rate power
From 1898 to 1923, there were sporadic attempts to 'regenerate' the parliamentary system, but King Alfonso XIII had no real desire for change and upheld the establishment
Spain's neutrality during World War I temporarily boosted its economy, freeing it from foreign competition, but the end of the war led to renewed competition, unemployment, and a fall in demand for agriculture
In 1917, army officers protested low pay, which escalated to include Catalan separatists, trade unions, and anarchists in the 'Assembly Movement' that demanded Catalan autonomy
In 1906, Spain acquired part of Morocco, leading to a series of campaigns against the Riff Tribes from 1906 to 1926, which promoted the emergence of a cohesive and experienced breed of army officers, the Africanistas (e.g. Franco)
In July 1921, the Rif leader Abd el Krim defeated Spanish forces at the Battle of Annual, resulting in the deaths of around 100,000 Spanish troops, leading to a parliamentary committee investigation into the responsibility for the disaster
To forestall the report of the parliamentary committee, which was thought might blame the King and precipitate the fall of the monarchy, Miguel Primo de Rivera, the military governor of Barcelona, declared a pronunciamento in September 1923, and Spain was ruled by patriots, not politicians
Primo de Rivera, who thought of himself as a benevolent despot, suspended the constitution, closed the Cortes, banned political parties, and set up a Directory of Generals to run the government
Primo de Rivera's regime coincided with political prosperity in 1929, supported by socialists and the UGT, and he attempted to fill the political vacuum by setting up his own party, the 'Patriotic Union'
Primo de Rivera's failures included an inability to reform the tax system, public works financed by budget deficits and loans, and the abolition of concessions to Catalonia and the prohibition of the official use of the Catalan language
The Great Depression in 1929 exposed the weaknesses of Primo de Rivera's economic policies, and his failure to reconcile the interests of key groups, along with the rising republicanism, led to his resignation and self-exile in France in 1930
After Primo de Rivera's dismissal, the new dictator Dámaso Berenguer ended some of the more repressive policies to diffuse opposition, leading to the nickname 'the toothless dictatorship'
In August 1930, leading opponents met in San Sebastián and formed the Pact of San Sebastián, uniting Spanish socialists, liberals, and even some conservatives and republicans in the army to coordinate opposition and plan a military coup to overthrow the government
Despite the dictatorship, the Spanish people were allowed to vote in regular local and municipal elections, and the municipal election of April 1931 showed the strength of the republican movement, with the King acknowledging that republicans had majorities in Spain's major urban areas, though the results were never published
When the King initially refused to acknowledge the election results, it led to widespread violence, and the Prime Minister, Berenguer, advised the King that he could not continue without the support of the Spanish people
The new provisional government, formed by a coalition of liberals and socialists from the Pact of San Sebastián, was tasked with supervising the creation of the Republic and organizing nationwide elections to establish a new democratic government