By Erik Kirschbaum

BERLIN (Reuters) - Support for the anti-immigrant Alternative for Germany (Afd) has fallen dramatically amid party infighting, racially-tinged criticism of Germany's popular national soccer team and even a local backlash over Britain's vote to leave the EU.

Analysts said the unexpectedly rapid implosion of the far-right AfD from 15 percent in opinion polls two months ago to a year-low of 8 percent on Wednesday could make it easier for Angela Merkel to retain power in next year's election.

Because Merkel's center-right conservatives, their center-left Social Democrat coalition allies and other parties reject any AfD alliance, the populist party's rise had cast doubt on her hopes of finding a partner big enough for a fourth term.

"All of a sudden, the populists aren't looking as attractive anymore," said Hans Vorlaender, political scientist at Dresden's Technical University. He said support was eroding due to bitter squabbling among AfD leaders and second thoughts on Brexit.

Britain voted in a referendum by a 52 to 48 percent margin on June 23 to leave the European Union. But several top leaders of the "Leave" campaign have since fallen by the wayside amid infighting over candidacies for top government posts and suggestions that some of their policy pledges were unrealistic.

"That Brexit leaders Boris Johnson and Nigel Farage ran away from responsibility so quickly showed AfD supporters they were promising an illusion," he added. "Their flight exposed the true colors and led to a lot of disillusionment toward populists."

Exacerbating the Afd's troubles, deputy leader Beatrix von Storch has drawn widespread condemnation for suggesting the German soccer team's semi-final defeat in the Euro championship tournament last week was the fault of the many players from immigrant families on the team.

Another AfD leader, Alexander Gauland, stirred outrage in May by saying most Germans would not want one of the team's black soccer stars, Jerome Boateng, as a neighbor.

Right-wing populist parties in Germany have a history of short shelf lives. In 1993, the Statt Partei (Instead Party) won 5.6 percent in Hamburg and up to 16 percent in local elections across Germany but collapsed as it drifted to the far right.

In 2001, the Schill Party enjoyed success in Hamburg, winning 20 percent of the vote. It tried to turn itself into a nationwide party but plunged into obscurity within six years.

"The AfD is being incredibly stupid, just like other far-right parties before it," said Hajo Funke, political scientist at Berlin's Free University. "Their leaders are openly tearing each other apart. The AfD is imploding faster than I expected."

Merkel has vacillated between trying to ignore the AfD, which began as an anti-euro party in 2013 and won 4.7 percent five months later in the last parliamentary election, and fighting it. Critics forecast it would self-destruct.

The AfD nearly collapsed in 2015 over another leadership battle but rebounded as a public backlash arose against Merkel's open-door policy toward refugees that saw Germany take in more than one million fleeing wars in Syria, Iraq and Afghanistan.

(Reporting by Erik Kirschbaum; Editing by Mark Heinrich)