The leaders of the far-right parties in Spain and Portugal have congratulated Germany's Alternative for Germany (AfD) on its election success in Saxony-Anhalt.

"Congratulations, Alice Weidel and Ulrich Siegmund, on this spectacular result, which represents great hope for Germany and Europe," Spanish Vox party leader, Santiago Abascal, wrote on X on Sunday.

Weidel is the AfD's co-leader, and Siegmund is the party's candidate to lead the state government - if it can get backing from at least one other party, as it failed to secure an absolute majority.

André Ventura, leader of the Portuguese Chega (Enough) far-right party, also wrote on X of the AfD's "historic victory."

Ventura said, "Germans are also increasingly opening their eyes to illegal and uncontrolled immigration, corruption and the appropriation of our freedom and identity. Congratulations!"

Both politicians attached a photo of themselves with Weidel alongside their congratulatory text.

Although Vox, Chega, and the AfD have all taken restrictive positions on migration, the two Iberian parties have sought to distinguish themselves from some of the AfD's positions to preserve their governing prospects and broaden their acceptance among middle-class voters at their national levels.

Vox and Chega belong in the EU parliament to the Patriots for Europe group, while the AfD belongs to the even further-right Europe of Sovereign Nations group.

Vox is polling at around 20%. In Spain, unlike in Germany, no firewall or policy is preventing more mainstream parties from cooperating with Vox.

The party governs in four autonomous communities, each in a coalition with the conservative People's Party (PP). Both would also like to replace the left-wing central government in Madrid led by Prime Minister Pedro Sánchez.

Chega is polling in third place with more than 20%, behind the socialist PS party and the conservative ruling alliance Aliança Democrática.

In Portugal, there is a firewall against Chega similar to that in Germany, but it is crumbling.