The United Nations has warned that the rapid build-up of migrants at Greece's northern borders risks leading to a humanitarian disaster.

The UN's High Commissioner for Refugees has said "Europe is on the cusp of a largely self-induced humanitarian crisis".

In a statement, the UNHCR urged better planning and accommodation for at least 24,000 people who are stuck in Greece.

The UNHCR urged all EU member states to reinforce their capacity to register and process asylum seekers through their national procedures as well as through the European relocation scheme.

The agency also said 131,724 refugees have crossed the Mediterranean already this year, more than in the first half of 2015.

Meanwhile, Macedonia's foreign minister has defended the use of tear gas against hundreds of migrants who tried to break through a fence at the Greek border yesterday.

Macedonian police fired volleys of tear gas at migrants, including women and children, who forced their way past a Greek police cordon and tried to break through a barbed wire fence into Macedonia.

In an interview with the BBC, Nikola Poposki also warned that pressure on the Balkans could spark conflict.

Thousands of migrants are stranded in Greece after Macedonia, along with other Balkan states including Serbia and EU members Slovenia and Croatia, imposed a daily limit on the number of migrants allowed to enter.

In a separate interview with German business daily Handelsblatt, Mr Poposki warned: "We have to be careful that it doesn't lead to conflict between neighbours.

"Slovenia sends back illegal migrants to Croatia, Croatia to Serbia, and Serbia to Macedonia etc.

"I fear that such a scenario could become reality with a high number of refugees.

"If in addition, pressure grows from the south of the Balkan route, then there could be a serious conflict situation in the Balkans. We must aim to avoid such a situation."

EU 'very concerned' by migrant crackdown

The European Union has said it was "very concerned" about the crackdown at the Greek-Macedonian border.

"The commission is very concerned by the images we saw yesterday," European Commission spokesman Margaritis Schinas told a press conference, adding all border measures must comply with international law.