Turkey's electoral body has been condemned for ordering Istanbul's local elections to be re-held after an opposition victory in March.
But CHP deputy chair Onursal Adiguzel said the rerun showed it was "illegal to win against the AK Party".
Mr Adiguzel tweeted that the decision was "plain dictatorship".
"This system that overrules the will of the people and disregards the law is neither democratic, nor legitimate," he wrote.
Related: Turkey’s Electoral Board orders re-run of Istanbul vote
And in a speech broadcast on social media, Mr Imamoglu condemned the electoral board, saying they were influenced by the ruling party.
"We will never compromise on our principles," he told the crowd. "This country is filled with 82 million patriots who will fight... until the last moment for democracy."
A supporters' group for Mr Imamoglu urged restraint, saying: "Let's stand together, let's be calm... We will win, we will win again."