The Macedonian prime minister says he would be open to changing his country’s name, raising hopes of an end to one of the world’s most unusual diplomatic spats – a 24-year linguistic dispute with Greece.

At its founding in 1991, when it declared independence from Yugoslavia, the country formally referred to itself as the Republic of Macedonia – to the fury of many Greeks, who feel that their northern neighbours stole the name from the eponymous Greek province that lies directly to the south of the Macedonian-Greek border.

Now the Macedonian prime minister, Nikola Gruevski, says he is willing to reopen dialogue on the issue with Greece – providing that any potential name-change is put to a plebiscite in Macedonia. “We are ready to discuss, to open dialogue with them, and to find some solution,” Gruevski said in an interview with the Guardian.

Greece has long accused Macedonia of appropriating significant aspects of Hellenic culture in order to build the national identity of a predominantly Slavic state, not least the sun symbol that inspired the Macedonian flag, and the ancient hero, Alexander the Great, after whom the main Macedonian airport is named.

The dispute prompted Greece to block its neighbour from joining both Nato and EU, and led the UN to refer to Macedonia as the Former Yugoslav Republic of Macedonia until the disagreement is resolved. Mooted name-changes have included adding qualifying words such as “upper” or “new” to Macedonia’s formal description – but no alteration has ever been agreed.

After years of intransigence on both sides, Macedonia’s leader has now implied he may be prepared to cede further ground to Greece, nearly two-and-a-half decades after the dispute first began in the aftermath of the breakup of Yugoslavia.

“We would like as soon as possible to go to dialogue with Greece to find a solution, and if we find a solution we have to go to the citizens and organise a referendum,” said Gruevski. “Through dialogue we have to find some solution, and after that to ask the citizens: is this right or not right?”

On both sides, there are other signals that the long-running dispute could be solved. Ahead of a visit to Athens on Thursday, Skopje’s foreign minister, Nikola Poposki, voiced optimism, telling the leading Greek daily, Kathimerini, that “conditions are more than ripe” for the name row to be resolved.

The visit, the first in 15 years, suggests that with Greece on its knees economically and Europe’s refugee crisis engulfing both, the Balkan neighbours are finally laying the ground for compromise.

Confidence-building measures have helped improve ties. Ending an 11-year embargo with a visit to Skopje in June, the Greek foreign minister, Nikos Kotzias, declared: “We want all our neighbours to be members of the European Union … because our own country, to great degree, is dependent on what happens in the Balkans as a whole.”

Prominent members of Alexis Tsipras’s leftist government have long indicated they would prefer to be shot of a problem blamed squarely on rightwing nationalism.

Fears in Athens of territorial aggression against the adjacent Greek province of Macedonia – stoked by what was perceived as the tiny republic’s exclusive claim to the name – have faded with time.

Having previously been adamant that no nomenclature would include the word Macedonia, Athens announced in 2007 that it would give its consent to a composite name in which it could feature. The statelet continued to insist that it be known as the Republic of Macedonia.

“We have gone the extra mile,” said one senior Greek foreign ministry source. “We’ve proposed a composite name with geographical qualifications for all uses.”

The issue will dominate Thursday’s talks. An immediate breakthrough is excluded. But Poposki’s visit – and the need to address other more pressing issues – may well augur the beginning of the end of one of the world’s quirkiest diplomatic disputes.