MOSCOW -- Hundreds of supporters gave Alexei Navalny a hero's welcome Saturday as Russia's most prominent opposition leader returned to Moscow the day after his unexpected release from custody in Kirov.
Mr. Navalny, who was sentenced Thursday to five years in prison on what many viewed as a politically motivated charge of embezzlement, immediately confirmed that he would run for mayor of Moscow in September despite the hurdles.
"We are going to run in this election, and we will win," he told a jubilant crowd at Moscow's Yaroslavl railway station. "Ahead of us is a big and difficult electoral campaign. Seven weeks of nonstop work, and that's just the start."
Mr. Navalny's triumphant return home from Kirov, 550 miles northwest of Moscow, capped a tumultuous week for the 37-year-old anti-corruption crusader, who was led in handcuffs from a court Thursday only to be set free within hours pending an appeal. That process could continue at least until the end of August.
Russia's state prosecutor has ruled that Mr. Navalny's continued detention would violate his right to run in the election. However, Russia's judiciary is not known for either independence or clemency, and many observers in Russia interpret the abrupt turn of events as a sign of a rift in the ruling elite.
Political commentators have suggested that the authorities want Mr. Navalny to run in the election because they see him as having little chance of winning. The likely victor is Sergei Sobyanin, whom the Kremlin appointed to a five-year term as mayor in 2010. Since then, Russia has decided to make the office elected. In early June, Mr. Sobyanin officially resigned, a maneuver that allowed President Vladimir Putin to appoint him as acting mayor until September.
The short preparation time before the election seemed designed to help Mr. Sobyanin prevail and go on to serve with a voter mandate.
Mr. Navalny has attributed his release to the spontaneous protests that erupted in Moscow and nearly two dozen other Russian cities after he was sentenced. "I would never have believed that I would be back here at Yaroslavl station within two days," he said Saturday. "I apologize that I did not believe in you more strongly."
However, close associates of Mr. Navalny confessed they were puzzled by the prosecutor's decision, which risked turning the activist into a political hero. Some speculated the authorities had decided it was less dangerous to let him go free than to face criticism for jailing him even before an appeal. It is widely expected that Mr. Navalny will be sent back to prison.
Riot police clad in black helmets and bulletproof vests took up positions at Yaroslavl station and in the surrounding streets early Saturday as Muscovites hurried to catch trains to their country houses at the start of the weekend.
Up until the last moment, station officials declined to reveal the platform where the 9:43 a.m. overnight train from Kirov bearing Mr. Navalny and his wife, Yulia, would arrive. But neither the confusion nor police appeals to the crowds to disperse prevented hundreds of Mr. Navalny's supporters from swarming onto the station concourse to meet their leader.