More than 50,000 protesters massed in the streets of northern Greece's biggest city Thessaloniki on Sunday, police said, in a long-running row between Athens and Skopje over the use of the name Macedonia.

Athens argues that the name Macedonia suggests that Skopje has territorial claims to the northern Greek region of the same name, of which Thessaloniki is the capital.

The region was the centre of Alexander the Great's ancient kingdom, a source of Greek pride.

Hardline clerics, far-right leaders and Greek diaspora groups had called for Sunday's rallies, with the turnout exceeding media estimates of 30,000.

Gathered around the statue of Alexander the Great in Thessaloniki were members of the neo-Nazi Golden Dawn party and local clergy.

Representatives from the main opposition party, New Democracy, were also present despite a tacit order from its liberal-minded leader Kyriakos Mitsotakis to boycott the protests.

Cretans in traditional costumes who travelled from the southern island with their horses, as well as people from northern Greece wearing costumes from the Macedonian wars era a century ago, crowded at the White Tower on the Thessaloniki waterfront from early in the morning.

Greece and Macedonia returned to the United Nations last week hoping to reach a compromise that could end the 27-year dispute over the former Yugoslav republic's name.

'Not negotiable'

Greece's objections to the use of the name Macedonia since the Balkan country's independence in 1991 have hampered the tiny nation's bid to join the European Union and NATO.

"We demand that the term Macedonia isn't included in the name which they will agree on. This is not negotiable," said Leonardou, a 59-year-old writer from Thessaloniki, warning that if the Greek government does otherwise "there will be an answer from the Greek people".

The UN negotiator Matthew Nimetz -- a 24-year veteran on the issue -- said last week that he was "very hopeful" that a solution was within reach.

Despite the nationalist fervour that is also being fed by Golden Dawn, Greeks appear to be less militant on the issue than in the past.

In 1992, more than one million people -- 10 percent of the population -- joined a rally in Thessaloniki to proclaim that "Macedonia is Greek".

According to a survey conducted for Greek radio station 24/7 by the Alco polling group, 63 percent of respondents said they thought it was in Greece's best interests to seek a mutually acceptable solution at the UN talks.

And the Greek Orthodox Church, which is traditionally opposed to the use of the term Macedonia from Skopje and led the 1992 rally, appears to have distanced itself from Sunday's events.

Tsipras, who is expected to meet with his Macedonian counterpart Zoran Zaev in Davos next week, said in an interview published on Sunday: "If there is an opportunity for a solution, it would be a national stupidity not to make good use of it."

However, he told Ethnos newspaper that he could understand "the concerns and sensitivities" of the Greeks of the north.

Macedonia is known as the Former Yugoslav Republic of Macedonia (FYROM) at the United Nations, although the Security Council acknowledged this was a provisional name when it agreed to membership.

If a deal is reached at the UN talks, it will be put before Greek parliament for approval, with the government expecting the compromise name to be approved despite opposition within some parties.

According to Macedonian media, Nimetz has proposed five alternatives all containing the name.