A Moscow court on Monday overturned a prison sentence for actor Pavel Ustinov, giving him instead a one-year suspended sentence, in a case that has sparked protests and a major solidarity campaign.

Ustinov, 23, was this month sentenced to three-and-a-half years in prison for violence against police at an opposition protest, despite his insistence he was simply a bystander.

A judge at the Moscow City Court said on Monday that the ruling by Moscow's Tverskoi district court should be changed, an AFP correspondent said.

The hearing took place after more than 25,000 people took part in an authorised opposition rally in Moscow on Sunday in support of those detained at anti-government protests, according to an independent monitor.

Ustinov's conviction sparked a major solidarity campaign, with supporters from film stars to priests to teachers, and saw hundreds of people also demonstrate outside President Vladimir Putin's administration.

Ustinov's case caused particular outrage because the court initially refused to consider video footage from the scene that showed police in an apparently unprovoked attack on the actor.

Ustinov was found guilty after one of the riot police accused him of causing a sprained shoulder.

In a backtrack last week, Ustinov was freed pending his appeal hearing.

He was released after prosecutors suddenly asked a court to give Ustinov a non-custodial sentence, saying his punishment was too harsh.

Initially, prosecutors asked a court to jail Ustinov for six years.

The apparent climbdown came after a harsh crackdown on the anti-government protests that has seen six people sentenced to jail terms of between two to four years and thousands of participants briefly detained.

Over the summer, tens of thousands of people took to the streets of Moscow after authorities refused to allow prominent opposition candidates to stand for the city parliament in September 8 elections.

Around 60,000 people rallied in Moscow at the peak of the demonstrations in August but the new wave of protests has since lost much of its momentum.