Michael Bloomberg took office shortly after the terrorist attacks of September 11, 2001 and continued the city's transformation as one where murders have dropped but the divide between rich and poor has grown.

The front-runner to replace him, Bill de Blasio, has focused on that divide and promoted himself as the cleanest break with the current administration. If he gets more than 40% of the primary vote Tuesday, he would avoid a second election among the top two finishers in his political party.

In a Quinnipiac University poll released, Mr de Blasio was the choice of 39% of likely Democratic voters.

His rise was unexpected. He placed his inter-racial family at the heart of his campaign.

City Council speaker Christine Quinn, who is trying to become New York's first female and first openly gay mayor, led the polls for most of the year but has seen support disappear as her rivals linked her to the bitter debate to let Mr Bloomberg run for a third term in 2009.

The city comptroller, John Liu, is trying to become the city's first Asian-American mayor but has been hurt by a fundraising scandal.

Republicans will look to continue an improbable winning streak. Although outnumbered by Democrats in the city 6-to-1, the party has won the last five mayoral elections.