An influx of people from crisis-hit southern European countries like Spain, Italy and Greece has led to the biggest surge in German immigration in nearly 20 years.

The Federal Statistics Office said 1.081 million immigrants flocked to Germany last year, up 13% from 2011 and the highest number since 1995. Leading the way were arrivals from eastern countries that joined the EU in 2004 or 2007, and those from southern eurozone members struggling with recession and high unemployment.

The number of immigrants coming from Spain, Greece, Portugal and Italy, for example, surged by 45% compared to the prior year, although the total inflow from these countries remains well below that from Poland and Romania.

"The rise in immigration from EU countries hit by the financial and debt crisis is particularly strong," the Statistics Office said.

Germany has been a rare pillar of strength during the crisis, benefiting from deep structural reforms introduced a decade ago, competitive small and medium-sized companies and record low interest rates resulting from its safe haven status.

Unemployment, at 6.9%, is hovering just above a post-reunification low. By contrast, more than one in four workers in Spain and Greece are without a job, and youth unemployment is close to 60%.

This has made Germany, Europe's largest economy, an attractive destination.