BERLIN (Reuters) - The three-year-old anti-immigration Alternative for Germany party has established a solid base among those Germans who demonstrate a political allegiance, a study showed on Wednesday.

The study by the German Institute for Economic Research and Humboldt University reinforces expectations that the anti-immigration party will make a strong showing in state elections next month in Berlin and Mecklenburg-Vorpommern in the east.

The party established three years ago by eurosceptics as a platform to oppose euro zone bailouts has been boosted by the influx of a record number of migrants into Europe last year.

The AfD entered three new state parliaments in elections earlier this year and now has deputies in half of Germany's 16 state assemblies.

The study found that some 5 percent of Germans who have supported a political party over a long period expressed sympathy for the AfD. Five percent is the threshold required to enter local parliaments and the Bundestag national parliament.

This threshold is also interpreted by the authors of the study as a sign that the AfD has harnessed enough loyal supporters to secure its survival over the medium- and long-term.

The AfD also draws support from people who have never voted before and supporters of far-right parties like the National Democratic Party (NPD), the study found, which partially explains its double digit percentage share of the vote in state elections.

The study, which drew on interviews with more than 40,000 people who have supported a political party over a long period of time, election results, opinion polls and political surveys, also found that AfD supporters tend of be mostly male, under 30, unemployed, poorly educated and living in the east of Germany.

The AfD is polling at around 10 percent nationally. In March, it won 24 percent of the vote in Saxony-Anhalt, to become the second-biggest party in the state parliament. It also won nearly 15 percent in the prosperous southern region of Baden-Wuerttemberg and over 12 percent in Rhineland Palatinate.

(Reporting by Joseph Nasr and Hans-Edzard Busemann Editing by Jeremy Gaunt)