Kremlin ally Sergei Sobyanin won a Moscow mayoral election on Sunday, two exit polls showed, but opposition leader Alexei Navalny did much better than expected and challenged the count.

The exit polls put Navalny on about 30 percent of votes, a strong showing which could energise resistance to President Vladimir Putin, and his campaign team said it believed Sobyanin had not crossed the 50 percent threshold for outright victory.

An exit poll by state-funded VTsIOM showed Sobyanin won 53 percent of votes versus 32 percent for Navalny, RIA news agency reported. Itar-Tass said an exit poll by the Public Opinion Foundation gave Sobyanin 52.5 percent and Navalny 29.1 percent.

But Navalny aides said its own exit polls showed Sobyanin received only 46 percent, not enough to avoid the embarrassment of a two-candidate runoff that would be risky for Sobyanin.

"Our exit poll data undeniably show that there will be a second round of this election," Navalny told campaign aides and journalists after the polls closed.  

Sunday's election pit Navalny, an anti-corruption campaigner who emerged from a wave of street protests as the driving force of opposition to Russian President Putin's 13-year rule, against Sobyanin, a former Putin administration chief who was appointed to a five-year term as mayor by the Kremlin in 2010, but called an early vote to bolster his legitimacy and try to extend his time in office. 

Putin, who has praised Sobyanin and suggested Navalny lacks the experience to run a city of nearly 12 million, repeated that message on Sunday without referring to any candidate by name.

"We need businesslike, no-nonsense, I would even say ... depoliticized people - technocrats who know how to work, know what to do and how to do it," he said in televised comments after casting his ballot at the Russian Academy of Sciences.

A win for Sobyanin would put a trusted ally in office as mayor of Moscow - which accounts for more than a fifth of Russia's economy - until after the 2018 presidential election, in which Putin has not ruled out seeking a fourth term.

Russian Jews divided

Navalny’s candidacy has divided Russian Jews, who were torn between the candidate of an establishment that has been generally good for the Jews and an opposition leader with nationalist associations some find troubling who nevertheless promises to restore democracy and good governance.

In pitching himself to Moscow Jews, Sobyanin can point to the opening of the Jewish Museum and Tolerance Center, a $50 million institution funded by the Russian state. Hanukkah celebrations are now held at the Kremlin, and under Putin’s leadership more than a dozen Russian cities have given land and building permits to Jewish communities.

Yet some Russian Jews find all this irrelevant.

“September 8 is not about electing the president of Russian Jewry,” said Michael Edelstein, a lecturer at Moscow State University and a writer for L’chaim. “Putin is good for Jews but he’s bad for Russia. For more than 20 years we did not have political prisoners. Now we do.” 

Even among those who voted for Navalny, there was little hope he could win and the threat of jail hangs over him.

He was convicted in July of stealing from a state firm and sentenced to five years in prison after a trial he and his supporters say was politically motivated. 

In a highly unusual ruling, a judge released him the following day pending a ruling on appeal, enabling him to continue his mayoral campaign.

"I hope there will be no violations today, I'd very much want Muscovites today to finally be able to express their will and chose the mayor they want," Navalny, flanked by his wife Yulia and their two children, said on leaving a polling station.

Many political analysts say the Kremlin wanted Navalny to run because it expected him to be humiliated and believed this would wipe out any political threat from a critic who has presidential ambitions.

While opinion polls conducted ahead of the election have shown Navalny has little or no chance of winning, his lively campaign has revived some of the enthusiasm of a flagging protest movement and may have rattled the Kremlin.  

Navalny and Sobyanin were among six candidates fighting for the ballots of nearly 7.2 million registered voters in Russia's biggest and wealthiest city, its main financial centre and the seat of most big Russian companies.