The crisis in Catalonia began on 1 October after the Catalan parliament held a referendum on independence which the Madrid government had already declared illegal.

The Civil Guard, Spain’s semi-militarised central police force, were sent in to stop people voting and were condemned for their heavy-handed tactics which saw them firing rubber bullets into the crowd and beating people as they arrived at polling stations.

Dismissed President Carles Puigdemont declared Catalonia to be an independent republic, only for Spanish Prime Minister Mariano Rajoy to impose Article 155 of the Spanish constitution – which allows the central government to take direct control of a province – and order fresh regional elections for 21 December.

Mr Puigdemont then accused Mr Rajoy of the “worst attack on Catalan institutions since the dictator General Franco ordered the end of our autonomy”.

He was referring to a long history of grievances between Spain and one of its most troublesome provinces.

Was Catalonia independent before?

Not really, but it has always been fiercely proud of its distinct language and cultural heritage and has always zealously guarded its autonomy.

Although many Spanish schoolchildren are brought up on the myth of the “Reconquista” – where Christian knights gradually pushed Muslim rulers out of the peninsula during the Middle Ages as part of a grand plan to unite Spain under Catholic rule – the country as we know it today largely came into being during the 16th century.

Catalonia independence referendum: Riot police clash with voters Show all 17 1 /17 Catalonia independence referendum: Riot police clash with voters Catalonia independence referendum: Riot police clash with voters A man faces off Spanish Civil Guards outside a polling station in Sant Julia de Ramis Reuters Catalonia independence referendum: Riot police clash with voters Riot police form a security cordon around the Ramon Llull school in Barcelona EPA Catalonia independence referendum: Riot police clash with voters Riot police evict a young woman during clashes between people gathered outside the Ramon Llull school in Barcelona EPA Catalonia independence referendum: Riot police clash with voters Spanish Civil Guard officers break through a door at a polling station in Sant Julia de Ramis Reuters Catalonia independence referendum: Riot police clash with voters Spanish National Police clash with pro-referendum supporters in Barcelona on Sunday AP Catalonia independence referendum: Riot police clash with voters Crowds raise their arms up as police move in on members of the public gathered outside to prevent them from voting in the referendum at a polling station where the President Carles Puigdemunt will vote later today Getty Catalonia independence referendum: Riot police clash with voters People confront Spanish Civil Guard officers outside a polling station Reuters Catalonia independence referendum: Riot police clash with voters Three man hold each other as they try to block a Spanish police van from approaching a polling station AP Catalonia independence referendum: Riot police clash with voters A woman shows a ballot to a Spanish Civil Guard officer outside a polling station Reuters Catalonia independence referendum: Riot police clash with voters A man wearing a shirt with an Estelada (Catalan separatist flag) and holding carnations faces off with a Spanish Civil Guard officer Reuters Catalonia independence referendum: Riot police clash with voters Police try to control the area as people attempt to cast their ballot at a polling station in Barcelona Getty Catalonia independence referendum: Riot police clash with voters A man is grabbed by officers as police move in on the crowds Catalonia independence referendum: Riot police clash with voters Two women argue with a Spanish National policeman during clashes between Catalan pro-independence people and police forces at the Sant Julia de Ramis sports centre in Girona EPA Catalonia independence referendum: Riot police clash with voters Sant Julia De Ramis in Spain Getty Catalonia independence referendum: Riot police clash with voters Confrontation outside a polling station in Barcelona, where police have tried to stop people voting AFP/Getty Images Catalonia independence referendum: Riot police clash with voters A Spanish National Police officer aims a rubber-bullet rifle at pro-referendum supporters in Barcelona AP Catalonia independence referendum: Riot police clash with voters Riot police clashed with voters as polls opened in Barcelona Sky News

After Ferdinand and Isabella conquered the last Muslim kingdom, Granada, and began to build an international empire, their grandson Philip II, husband of Mary Tudor, became the first ruler to declare himself the “King of Spain” instead of each individual Spanish kingdom.

To this day Spain remains something of a mishmash of different territories which each have their own distinct heritage and traditions – the Spanish national anthem famously has no lyrics because they cannot agree on what to say.

So is Catalonia like the other Spanish regions?

Many of the other regions have their own languages and separate cultural traditions but in Catalonia, along with the equally restive Basque Country, the desire to emphasis the difference seems particularly pronounced.

The Catalan language comes from the same Latin root and has many similarities with Spanish (unlike Basque) but it is recognised as distinct.

Catalonia has always seen itself as separate from the rest of Spain as it has historically had its own regional government.

Basque independence supporters stage a solidarity march with Catalonia in the northern village of Lazkao. Madrid is concerned Catalan independence will encourage other separatist regions (AFP/Getty Images)

It maintained a degree of autonomy under the Spanish crown until the early 18th century when King Felipe V signed a series of decrees which clamped down on the region's independent institutions, language and culture.

He was a newly installed king from the French royal family who had come to power after the War of Spanish Succession between France on one side and Britain and Austria on the other, after the last king died without an heir.

The Catalans had sided with the British and the Austrians during the war and declared independence, but had been forced to become part of a centralised Spain based on a similar model of government in France.

When Spain was declared a republic in 1931, Catalonia was granted an autonomous regional government but this proved short-lived as the country soon erupted in civil war which led to the fascist General Francisco Franco coming to power.

A Catalan independence flag. Catalan independence activists say the region has a long history of being oppressed by Spain (Getty Images) (Getty)

Franco seized control of Barcelona in 1939 and executed Catalonia's political leaders, including former Catalan president Lluís Companys, at the fortress on the Montjuic hill which overlooks the city in 1940.

For decades the Catalans suffered under his harsh rule as political opposition was violently suppressed as well as their autonomy, language and culture. Their regional government was only restored in 1979, four years after his death.

The Catalan language was also given equal status with Spanish as an official language of government for the first time.

So it is a historical grievance then?

Not entirely. Although the longest history of oppression and centralisation from Madrid has cast a shadow over the modern age – and is often used as a rallying call by pro-independence politicians – it is modern-day politics and economics which are driving this latest constitutional crisis.

In 2010, a decision by the Spanish Constitutional Court – the country’s equivalent of a Supreme Court – struck down a law passed by the Catalan parliament in 2006 which updated the autonomous government’s statute from 1979 which mapped out its relations with the rest of Spain.

The court struck down 14 articles and curtailed another 27 of the 223 articles in the statute – rejecting a pledge to place the importance of the Catalan language above Spanish and anything that suggested Catalonia was a “nation” as opposed to a “region”.

This led to massive street protests and the rise of the pro-independence political parties who now control the Catalan parliament.

In 2014 there was an unofficial referendum (with an estimated turn out of 37-41%) on independence in which 80 per cent of voters said they wanted Catalonia to be an independent state.

But unlike in 2017, the Catalan government branded it as a “popular consultation process” to gauge public opinion and did not threaten to declare independence unilaterally.

It’s the economy stupid

The renewed bid for political independence came at a time when Spain as a whole was facing an acute financial crisis.

It was one of four massively indebted Eurozone countries, alongside Portugal, Ireland and Greece, who were forced to go to the European Union for a loan to shore up their finances.

This and the years of harsh austerity policies that followed lead to the rise of populist parties across Spain and an increasing frustration in the wealthy Catalonia.

The Catalonia crisis explained in 60 seconds

Catalonia is the richest region in Spain and if it successfully seceded Madrid could lose 20 per cent of its GDP.

Many Catalans feel they are paying high taxes and suffering under austerity to shore up the profligacy of a country they have little in common with.

A large proportion believe they will be wealthier and more successful if they go it alone in future.

So what’s next?

It is currently unclear. Barcelona and Madrid are currently locked in stalemate and there appears to be no immediate risk that the army will be deployed to the streets of Barcelona.

The Madrid government’s next step would be to arrest Mr Puigdemont for sedition, which carries up to 25 years in prison, but appear to have adopted a “wait and see” approach.

Neither side wants to resort to violence and Madrid is conscious of not encouraging similar independence movements in the Basque Country and Galicia.

People waving Spanish flags from the Casa Batllo in Barcelona during an anti-independence rally. It is unclear how much support there is for declaring unilateral independence (AFP/Getty Images)