Madrid, Barcelona and some other cities were hit by violent protests this week in the wake of the imprisonment of a left-wing rapper for inflammatory messages on social media.
By Thursday morning, 61 people had been detained for rioting over the previous two nights and more than 80 reported injured. The demonstrations were against the nine-month prison sentence handed out to rap singer Pablo Hasél for praising terrorism and dishonouring and spreading falsehoods about the monarchy and State security forces in 64 messages on Twitter and a song on YouTube.
After 32-year-old Hasél failed to turn up to start his prison sentence last Friday, on Monday he barricaded himself inside the University of Lleida, Catalonia, with supporters to resist arrest.
He explained on social media that he was taking the action "to let people know more about what they are doing, make the arrest harder and call for an organised fight for freedom of expression and other rights and freedoms".
Judges had refused to suspend Hasél's prison sentence as he has previous convictions.
Before police entered the university on Tuesday, Hasél tweeted, "If this is the last I write before being imprisoned, it's time to organise against this tyranny."
Amid political argument over free speech, Unidas Podemos has supported the protests and a pardon for Hasél. The conservative PP said it was "irresponsible" for governing parties to feed "these violent acts".
By Thursday night 90 arrests had been made.