VIENNA/LJUBLJANA (Reuters) - Austria said on Friday it would deny entry to migrants intending to pass through its northern neighbor Germany rather than apply for asylum there, prompting Slovenia to its south to announce a similar move to avoid becoming a refugee bottleneck.

Migrants stay in queue during heavy snowfall before passing Austrian-German border in Wegscheid in Austria, near Passau November 22, 2015. REUTERS/Michael Dalder -

Slovenia and Austria, straddling the route of asylum seekers trekking from the Mediterranean toward wealthy northern Europe, acted after Germany began turning back migrants aiming to pass through to points further north, mainly in Denmark and Sweden - which have both tightened border controls to stem the influx.

Germany has been sending a few hundred migrants back over its border into Austria every day since the start of January, Austrian police said. Many of those barred lack valid documents but seek to travel onwards to Sweden.

“What is the situation currently on the German-Austrian border? That only those who want asylum in Germany are being let through, and those who want to travel onwards are sent back,” Austrian Interior Minister Johanna Mikl-Leitner told state broadcaster ORF. “We will stop them directly on our southern border (with Slovenia) as of the end of next week,” she said.

A Slovenian interior ministry official said later that Slovenia would have to follow suit in order to avoid a buildup of migrants in the tiny Alpine state of 2 million people.

State secretary Bostjan Sefic said Slovenia was liaising with Austria, Germany and other countries on how to control the migrant flow, which has kept up despite frigid winter cold.

“The states have agreed that a joint solution has to be reached,” Sefic told reporters. He said Slovenia would have to act on its own in the event that no joint solution was agreed.

Hundreds of thousands of migrants have streamed through Slovenia and Austria into Germany since September, when the countries threw open their borders to a wave of people fleeing war and poverty in the Middle East, Afghanistan and elsewhere.

Germany itself has taken in 1.1 million migrants, the vast majority of those to have entered Europe over the past year. But it is rethinking its open door refugee policy in the face of increasing difficulties housing migrants and a spate of sexual assaults on women by young male asylum seekers.

Only about 90,000 have applied for asylum in Austria last year but fears about migrants have nevertheless contributed to a rise in support for the nationalist far right.

Government ministers from the Social Democrats and their junior coalition partner, the Austrian People’s Party, have said more must be done to reduce the number of people arriving, though they have disagreed on how to achieve that.