German police should "if necessary" shoot at migrants seeking to enter the country illegally, the leader of a right-wing populist party has said.
Frauke Petry, head of the eurosceptic Alternativ fuer Deutschland (AfD) party, told a regional newspaper: "I don't want this either. But the use of armed force is there as a last resort."
Her comments were condemned by leftwing parties and by the German police union.
More than 1.1 million migrants arrived in Germany last year.
Also on Saturday, German Chancellor Angela Merkel said most migrants from Syria and Iraq would go home once the wars in their countries had ended.
She told a conference of her centre-right CDU party that tougher measures adopted last week should reduce the influx of migrants, but a European solution was still needed.
Police must stop migrants crossing illegally from Austria, Ms Petry told the Mannheimer Morgen newspaper (in German), and "if necessary" use firearms.
"That is what the law says," she added.
A prominent member of the centre-left Social Democrats, Thomas Oppermann, said: "The last German politician under whom refugees were shot at was Erich Honecker" - the leader of Communist East Germany.
Germany's police union, the Gewerkschaft der Polizei, said (in German) officers would never shoot at migrants.
It said Ms Petry's comments revealed a radical and inhumane mentality.
The number of attacks on refugee accommodation in Germany rose to 1,005 last year - five times more than in 2014.
A note on terminology: The BBC uses the term migrant to refer to all people on the move who have yet to complete the legal process of claiming asylum. This group includes people fleeing war-torn countries such as Syria, who are likely to be granted refugee status, as well as people who are seeking jobs and better lives, who governments are likely to rule are economic migrants.