Environmental campaigners from Extinction Rebellion won a legal challenge on Wednesday against a blanket ban on their protests, imposed by London police last month.
The UK High Court ruled that the authorities were wrong to enact the prohibition, which outlawed gatherings of more than two people during a 10-day protest that paralysed parts of central London.
"The decision to impose the condition was unlawful," two senior judges said in their ruling.
The legal victory delivered the year-old protest group a welcome boost after a controversial campaign ended with commuters attacking an activist who halted a train during the morning rush hour.
The incident prompted Extinction Rebellion to promise to rethink its strategy.
The police made more than 1,800 arrests and charged nearly 200 people during the campaign.
Extinction Rebellion lawyer Tobias Garnett said the group was "delighted" with the ruling.
"It vindicates our belief that the police's blanket ban on our protests was an unprecedented and unlawful infringement on the right to protest," the lawyer said.
The London police department defended its decision but did not contest the ruling.
Assistant Commissioner Nick Ephgrave argued that the protest ban "was made with good intent and based upon the circumstances confronting the command team at the time".
"Nevertheless, this case highlights that policing demonstrations like these, within the existing legal framework, can be challenging."