The possibility of Macedonia joining the EU edged a step closer after it agreed to change its name to end a 27-year dispute with Greece.
The country will now be known as the Republic of North Macedonia, or Severna Makedonija in Macedonian.
The move was broadly welcomed by senior EU officials and MEPs.
The name dispute has soured relations between the two neighbours since 1991, when Macedonia broke away from the former Yugoslavia.
After the announcement was made on Wednesday, Austrian Chancellor Sebastian Kurz said that Austria, which takes over the EU presidency next month, thought Macedonia had a chance of joining the European Union.
Bulgaria, the current holder of the EU's rotating six-month presidency, also said the deal paved the way for accession talks.
Greece had argued that the young country's name implied a claim to the territory and ancient heritage of Greece's northern region of Macedonia.
"This historic agreement is testament to many years of patient diplomacy and to the willingness of these two leaders to solve a dispute which has affected the region for too long" Nato Secretary General Jens Stoltenberg
Previous administrations in Macedonia's capital, Skopje, resisted demands to change or modify the name.
The dispute strained relations between the two countries, and the United Nations appointed a special envoy to mediate.
Greece will now lift its objections to Macedonia's accession to Nato and the European Union.
Reaction to the news was swift with the EU’s High Representative Federica Mogherini and EU enlargement commissioner Johannes Hahn both issuing statements which congratulated Greece and Macedonia on their "historic agreement".
“As a founder member of the Friends of Macedonia I'm delighted this small landlocked state has finally resolved its name dispute with neighbouring Greece” UK Tory MEP Charles Tannock
In a joint statement, the pair said: "This achievement belongs to the leaders of the two countries and their teams, but first and foremost it belongs to all the citizens of both countries, and of Europe as a whole.
"We must now make good use of the window of opportunity that has been pushed wide open to accompany and consolidate the winds of peace and cooperation in the entire region."
Further comment came from Nato Secretary General Jens Stoltenberg who added: "This historic agreement is testament to many years of patient diplomacy and to the willingness of these two leaders to solve a dispute which has affected the region for too long."
Also speaking on Wednesday, UK Tory MEP Charles Tannock told this website, “As a founder member of the Friends of Macedonia I'm delighted this small landlocked state has finally resolved its name dispute with neighbouring Greece.”
The ECR member said, “I happen to be a strong friend of Greece too and have never fully understood the degree of sensitivity over a name as an outsider.”
“However I am conscious that this issue remains a delicate one and requires national parliamentary and possible referendum endorsement still, but the international community and EU must get fully behind the deal and the EU must give the Green light to opening accession negotiations for Macedonia to join the EU as North Macedonia which is its new agreed name.”