North. It’s just a single five-letter word, but in Macedonia in recent weeks it has prompted many column inches of debate, hours of coffee-shop discussions and pages of online abuse.

A referendum at the end of the month will ask citizens whether they are willing to add the word to the country’s official name, making it the Republic of North Macedonia.

The change is the main part of an agreement between Macedonia and Greece signed by their respective prime ministers in June. Greece has long blocked Macedonian accession to Nato and the European Union, claiming its northern neighbour’s name is an unfair appropriation from the northern Greek region of Macedonia.

For many inside Macedonia, changing the name is a delicate issue. “It’s not just about one word. Think about Northern Ireland and Ireland. Words have meaning,” said Sasho Klekovski, a pollster and analyst who opposes the deal.

Nikola Dimitrov, Macedonia’s foreign minister, who spent months in negotiations with his Greek counterpart hammering out details of the deal, said it would offer a new path forward for the small nation of around 2 million people, which has struggled since it became independent after the collapse of Yugoslavia.

“We have lost a generation. I am 45, I was 18 when Macedonia became independent. In a way this is the second chance for our generation to make it,” he said in an interview at his office in central Skopje, Macedonia’s capital.

On 30 September the population will be asked: “Are you in favour of Nato and EU membership, and accepting the name agreement between the republic of Macedonia and Greece?”

Government critics say the wording is manipulative, but the defence minister, Radmila Šekerinska, said it was quite proper to phrase the question in two parts. “If there was a chance to get into the EU and Nato without the agreement with Greece, everyone would be thrilled,” she said. “To deny the connection between the EU and Nato and the agreement is to be irrational.”

Few Macedonians are positive about the name change, but many speak of it with the grudging acceptance that might be accorded an unpleasant but necessary medical procedure.

“We are an isolated, small and poor country, so let’s do it. It’s not fair, but it’s not about what is fair but about what is good for everyone. If there’s a chance for people to live better, let’s take it,” said Sanja Arsovska, 31, an actor at the Skopje drama theatre.

The deal has been stridently opposed by nationalists on both sides of the border – on Saturday Greeks protesters clashed with riot police – but polls suggest a slim majority are in favour of the deal, boosted by overwhelming support among Macedonia’s sizeable ethnic Albanian minority.

Protests in Thessaloniki, Greece, against the agreement reached with Macedonia. Photograph: Aris Messinis/AFP/Getty Images

The longstanding dispute between Skopje and Athens has been complicated in recent years by a “antiquisation” project carried out by the nationalist government of the previous prime minister Nikola Gruevski, in which dozens of statues, fountains and grand buildings adorned with faux-marble columns were erected in Skopje.

The centrepiece is a fountain complex in the main square, topped with a statue of Alexander the Great on horseback. The monuments incensed Greece, who accused Skopje of appropriating Hellenic cultural and historical heritage.

Gruevski was ousted from office in 2016 after a wire-tapping scandal and is now on trial for an array of offences. The new government reached the deal with Greece but will need the support of parts of Gruevski’s VMRO-DPMNE party to see it through, as the referendum is only consultative.

Western diplomats are suggesting that a yes vote, even with a turnout below the 50% threshold required for it to stand, would be a mandate for change. The ruling coalition would need to persuade around 10 MPs from VMRO to vote with them in order to attain the two-thirds majority required for constitutional change.

VMRO officials are furious that Macedonia will have to change its name not only in international communications but internally as well, with passports, ministry names and all other references to Macedonia to be replaced by North Macedonia.

“They would have had a better agreement if they had let the Greeks write it themselves, because probably the Greeks would have been a bit embarrassed to give themselves absolutely everything,” said Aleksandar Nikoloski, the deputy head of VMRO, in an interview at the party headquarters, an imposing building filled with lurid artworks that reflect Gruevski’s grandiose visions.

VMRO are under intense international pressure not to scupper the agreement and have yet to announce whether or not they will call for a boycott of the referendum. Nikoloski has denied government claims that the party offered to support the deal in exchange for an amnesty for Gruevski and others.

The Greek and Macedonian prime ministers, Alexis Tsipras (left) and Zoran Zaev in June. Photograph: Nake Batev/EPA

As well as trying to get the opposition onside, Macedonian officials are keeping an eye on Moscow during the campaign. Russia has openly said it opposes Macedonia’s Nato accession and has been accused of working behind the scenes to try to scupper the deal. Greece recently expelled Russian diplomats, accusing them of offering bribes to opponents of the deal.

In Macedonia, the main pro-Russia force is Janko Bachev, a fringe politician whose United Macedonia party has sprung up in recent months. Bachev, speaking from the party offices where a Russian flag flies from the balcony, claimed the polls showing a majority of Macedonians in favour of Nato membership were “funded by the CIA” and insisted most Macedonians opposed the deal.

“All the main parties here support liberal values such as homosexuality, gay marriage, changing Macedonia’s name and erasing everything that is Macedonian,” he said, adding that the Kremlin instead supported “traditional values” that aligned with the views of most Macedonians. He denied receiving funding from Russia but said he wanted Macedonia to enter into a strategic alliance with the Kremlin.

Bachev, who is calling for a boycott of the vote, is not seen as a serious political force by most observers, but western diplomats are nevertheless following Moscow’s moves warily.

“For years, Russia never said anything about Macedonia; suddenly they are coming out with all kinds of statements,” said one. “I don’t think they are going to launch a Montenegro-style coup here, but could they put a few guys into a crowd and create a disturbance? I wouldn’t rule that out.”

Western countries are pushing strongly for the deal to be a success, with Germany’s Angela Merkel visiting Skopje this weekend.

If the deal is pushed through, Skopje and Athens have agreed to disagree on who or what constitutes a Macedonian: a sub-clause of the agreement says “the parties acknowledge that their respective understanding of the terms ‘Macedonia’ and ‘Macedonian’ refers to a different historical context and cultural heritage”.

When it comes to the Skopje monuments of Alexander the Great and other classical heroes, the government has agreed that within six months it will take “corrective action” by renaming monuments that “refer in any way to ancient Hellenic history and civilisation”.

Dimitrov said: “In the past we sacrificed our reality for mythology. Now we are sacrificing mythology for reality, and reality is what really matters.”