Hundreds of migrants have rushed at Macedonian border forces in an attempt to enter the country from Greece.
The security forces beat back the migrants with truncheons and riot shields. A number of people were injured.
On Thursday, Macedonia declared a state of emergency to cope with migrants – many from the Middle East – who are trying to reach northern EU states.
The UN urged both Greece and Macedonia to tackle a “deteriorating situation”.
Some 44,000 people have reportedly travelled through Macedonia in the past two months, meeting little border resistance, but razor wire has now been rolled across the frontier to prevent people from entering.
Medecins Sans Frontieres said it had treated 10 people with wounds from stun grenades fired by Macedonian troops, near the Greek border village of Edomeni.
Amnesty International deputy Europe director Gauri van Gulik said: “Macedonian authorities are responding as if they were dealing with rioters rather than refugees who have fled conflict and persecution.”
Macedonian Foreign Minister Nikola Poposki told the BBC that his government had been forced to act because the numbers trying to enter Macedonia had recently soared to more than 3,000 a day.
He said a small country such as his could not cope with such an influx.
Police have issued temporary transit documents to 181 migrants in the past 24 hours.
Spokesman Ivo Kotevski told Reuters: “We are allowing entry to a number that matches our capacity to transport them or to give them appropriate medical care and treatment.”
The BBC’s James Reynolds, who was at the scene, says that later on Friday he saw some families being allowed to cross – they smiled with relief as they walked to a train station so they could head north to Serbia, Hungary and the rest of Europe.
The UN refugee agency, the UNHCR, on Friday expressed concern for “thousands of vulnerable refugees and migrants, especially women and children, now massed on the Greek side of the border amid deteriorating conditions”.
It urged Macedonia to “establish an orderly and protection-sensitive management of its borders” while appealing to Greece to “enhance registration and reception arrangements” on its side of the border.
The UNHCR also said it had been assured by Macedonia the border “will not be closed in the future”, but did not elaborate.
In recent weeks there have been chaotic scenes at Gevgelija station, with migrants trying to clamber on board packed trains bound north.
As well as Gevgelija, Macedonia declared a state of emergency in northern Kumanovo, where migrants attempt to travel on to Serbia, the next stop before entering Hungary, which is part of the EU.
Greece itself has seen almost 160,000 people landing on its shores since January, the UN estimates, with 50,000 arriving in the past month alone.
A German journalist with Bild, Paul Ronzheimer, said he had witnessed a Greek border guard explaining to a group of Syrian refugees from Aleppo how to cross into Macedonia.
Speaking to the BBC’s Outside Source programme, he said he had asked the guard why he was helping them cross illegally.
According to Ronzheimer, “He replied: ‘We can’t handle the situation, there’s hundreds of thousands of migrants in Greece right now and we want them out – they don’t want to stay in Greece, they want to go to Germany.'”
The migrants trying to reach northern and western Europe come from the Middle East, Africa and Asia. Many arriving in Macedonia are escaping the conflict in Syria.