Germany holds a general election in September and the AfD is expected to enter the Bundestag national parliament for the first time, a worrying prospect for Germans still fearful of xenophobia in politics more than seven decades after the defeat of the Nazis.
"Philipp Lahm should look after his football and leave politics to others as much as possible," Georg Pazderski, AfD leader in the Berlin city parliament, told mass-selling daily Bild.
"If he wants to do politics, he should enter politics and be active there."
Lahm, who is considered one of the best players of his generation, told the Welt am Sonntag newspaper at the weekend: "I think what presumably most Germans think: that Germany should not veer to the right."
Lahm retired from international football after winning the World Cup with Germany in Brazil three years ago. He plans to stop playing altogether at the end of this season with Bayern Munich.
"The wrong ones, the populists, should not have more power," Lahm said. "The election in the Netherlands is the latest example. The right-wing populists - thank God - were not as strong as was feared.
"But in the spring, France will vote, in the autumn it's Germany. I think it is important that we not only think about it but above all speak about it."
The Party for Freedom of anti-Islam Dutch politician Geert Wilders won fewer parliamentary seats than had been projected in polls before the election last month, a relief for Prime Minister Mark Rutte and mainstream politicians across Europe who are contending with a rise in anti-establishment movements.
The AfD are polling at around 8 percent after seeing their support fall by more than a third.
(Reporting by Joseph Nasr; Editing by Andrew Bolton)