Rioters fought running battles with police in Barcelona after more than half-a-million people took to the streets to demonstrate against the convictions of political figures behind Catalonia’s independence movement.

A general strike had already shut down the city when 520,000 people took to the streets – including some who had marched for days from five neighbouring cities.

As night fell, masked youths blocked a broad boulevard close to the city's police headquarters, setting fire to large bins and throwing a hail of stones, cans and bottles towards massed lines of security forces in full riot gear.

Defending the police building, officers responded with repeated volleys of foam bullets, smoke grenades and tear gas, while a water canon roamed the area to douse flames.

A branch of the Santander bank was also ransacked amid the chaos, while officials said there were clashes in at least four other towns and cities in Catalonia.

Every time that Catalonia has revolted - in pictures Show all 14 1 /14 Every time that Catalonia has revolted - in pictures Every time that Catalonia has revolted - in pictures Reapers' War In 1640, amidst the Thirty Years War, Philip IV of Spain sent his Castilian soldiers into the Catalan region to defend the border with France. The soldiers were not on their best behaviour and drew the ire of the Catalan peasants and politicians alike, at a time when the region was already agitated by economic decline. On June 7, reapers arriving to Barcelona for seasonal harvest work were dismayed to find little of the sort and blamed the stationed soldiers. After a reaper was killed, the revolt began in full force with a fierce uprising known as Corpus de Sang (depicted here in a 1910 painting by Ermenegild Miralles) Ermenegild Miralles i Anglès Every time that Catalonia has revolted - in pictures Reapers' War More Castilian forces arrived, strengthening the Catalan resolve and leading Pau Claris, President of the Generalitat (Catalonia's political assembly) to declare Catalonia an independent republic on January 17 1641. A week later the republic swore its allegiance to Louis XIII of France and the war came to a head at the Battle of Montjuïc (depicted above by Pandolfo Reschi) where the Franco-Catalan forces were victorious. Following negotiations, Catalonia became an independent republic under the protection of France Pandolfo Reschi Every time that Catalonia has revolted - in pictures War of the Spanish Succession As Charles II of Spain died in 1700 without an heir, a variety of nations and other powers across Europe had their own ideas of who ought to succeed him. Catalonia sided with the Austrians, English and the Dutch in endorsing Archduke Charles of Austria, a Habsburg. Unsuccessful in their aims, they were violently brought back under the Spanish crown by the victorious Phillip V. (Depicted above is the Battle of Almansa, a decisive battle in the War of the Spanish Succession) Ricardo Balaca Every time that Catalonia has revolted - in pictures Tragic Week The conflict of the Tragic Week of July 1909 resulted from Spanish Prime Minister Antonio Maura's desire for power gains in Morocco. He relied on, mostly poor, Catalonian conscripts for the cause, who questioned the motives of the conflict and doubted their chances of survival Every time that Catalonia has revolted - in pictures Tragic Week A general strike commenced on Monday 26 July. By midday the crowds had set fire to the San José Workers’ Foundation, the first of around 80, mostly religious, buildings that they would burn that week. Soldiers and police barricaded streets and fought openly with the strikers Alamy Every time that Catalonia has revolted - in pictures Tragic Week By the end of the week, the police and army had taken control. Over 1000 strikers were arrested and 5 leading figures executed. This caused disgust across Spain and wider Europe and the episode contributed to the downfall of Maura's government Getty Every time that Catalonia has revolted - in pictures The Spanish Civil War In the Spanish Coup of July 1936, Republican forces opposed the Nationalist presence in Catalonia. The National Confederation of Labour (CNT), an anarchist organisation, began to take hold of power in Catalonia AFP/Getty Every time that Catalonia has revolted - in pictures The Spanish Civil War As the CNT took control of the Generalitat, companies and organisations were ordered to collective control Getty Every time that Catalonia has revolted - in pictures The Spanish Civil War Nationalist forces eventually regained control of the territory. Pictured are their tanks entering Barcelona in 1939 Getty Every time that Catalonia has revolted - in pictures The Spanish Civil War Barcelona nationalists rejoice at the arrival of General Franco's forces. Catalonia, along with the rest of Spain, was to remain under dictatorship until 1975 Getty Every time that Catalonia has revolted - in pictures Independence Referendum 2017 In 2017 the Generalitat passed a motion that a referendum would be held on Catalan independence. The Constitutional Court of Spain ruled that the referendum was a breach of the Spanish constitution, therefore illegal Reuters Every time that Catalonia has revolted - in pictures Independence Referendum 2017 Catalan government buildings were raided in the lead up and polling stations were blockaded by police on the day but the vote went ahead illegally. Turnout was 43% and of those 92% voted for independence Reuters Every time that Catalonia has revolted - in pictures Independence Referendum 2017 Catalan President Carles Puigdemont declared victory and is pictured here signing a declaration of independence on October 27. Warrants were issued for the arrest of Puigdemont and five other Catalan politicians and the Spanish government did not recognise the result and imposed direct rule over Catalonia, as opposed to its then status as an autonomous community of Spain Reuters Every time that Catalonia has revolted - in pictures 2018 A year on from the vote Spain has ended direct rule in the region and dropped the arrest warrants. But on the anniversary of the vote, more than 180,000 protesters took to the streets of Barcelona with the cry "1 October, no forgiving, no forgetting" AFP/Getty

The protests began after the Spanish Supreme Court decided to jail nine separatist leaders for their role in a failed 2017 independence referendum earlier this week, on charges including sedition.

Unlike the peaceful protests that led up to the independence ballot – which was ruled illegal by Madrid – scores have been arrested in violent exchanges with national and regional police.

Protesters have set up and ignited barricades in the streets of the Barcelona.

More than 200 police officers treated for injuries since Monday.

Health authorities said 62 people were harmed across Friday evening alone, including 41 in Barcelona.

Around 107 police vehicles have been damaged while 800 bins are reported to have been burned as barricades over the same period.

Spanish authorities suspect a secretive new group called Tsunami Democratic is using encrypted messages to orchestrate some of the attacks.

The group appeared in September and in just over six weeks has gained nearly 340,000 followers on its main channel in Telegram, a messaging app.

A National Court judge ordered the closure of websites linked to the group on Friday.

More than 120 people have been arrested during the demonstrations.

It comes amid fears the independence movement has been pushed towards violence by fringe separatist groups who do not share the core movement’s views on non-violent protest.

Rights group Amnesty International called on "all authorities" to refrain from contributing to the escalation of tensions in the streets and to respond "proportionally" to outbreaks of violence.

The group said it had observed "various cases" of "excessive" use of police force, including “inappropriate and unjustified use of batons” against people “who posed no risk."

But Spanish judge Fernando Grande-Marlaska defended the police action and warned that demonstrators could face six-year prison sentences for their involvement in the riots.

Miquel Buch, Catalonia's pro-independence interior minister, said "This kind of violence is unprecedented in Catalonia ... these people are not separatists."

Tourists also felt the turmoil on Friday after cruise operators diverted their ships to other ports, and those which had already docked in the port of Barcelona cancelled their passengers' excursions to the city.

Tourist attraction Sagrada Familia also closed its doors due to a protest outside the basilica.

Dozens of flights into and out of the region were cancelled due to the strike. Picketers also blocked roads to the border with France and elsewhere.

Commuter and long-distance train services were significantly reduced, and many shops and factories did not open for business.

Support free-thinking journalism and attend Independent events

Friday's violence erupted after former Catalan leader Carles Puidgemont handed himself in to Belgian authorities, after Spain issued a new warrant for his arrest.

Mr Puigdemont – the former president of Catalonia – has been living in self-imposed exile in Belgium to avoid charges of sedition against the Spanish region, as well as misuse of public funds.

The charges were brought against him by prosecutors for his role in Catalonia’s failed unilateral declaration of independence in 2017, after which he fled the country.

His office said that he had “in the company of his lawyers, voluntarily appeared before Belgian authorities”.

Spain's interim prime minister, Pedro Sanchez, said authorities would prosecute radicals who rioted this week while ensuring that peaceful protests can continue.

"Those who break the law have to answer for their deeds sooner or later," Sanchez told a press conference in Brussels, where he was attending a European Union summit.