Image copyrightGetty ImagesImage caption
Hamburg has long suffered a shortage of cheap social housing

Hamburg's new law is described as a temporary, emergency measure. Owners of empty commercial properties will be compensated. The law does not include residential properties.

But the conservative opposition in the city, in the north of Germany, condemned the move.

The authorities in Bremen, a city just west of Hamburg, are considering passing a similar law.

Mass brawl

Germany expects to host at least 800,000 asylum seekers this year - about four times the number it had last year.

Many are from war-torn Syria, Iraq and Afghanistan. But the thousands arriving also include asylum seekers from Kosovo, Albania and other Balkan countries, whose claims are usually rejected.

On Thursday more than 200 migrants fought each other in a mass brawl at a reception centre in Hamburg-Bergedorf. Police said Syrians and Afghans were involved in the latest clash.

Image copyrightEPAImage caption
Dozens of police went to quell a migrant brawl in Hamburg-Bergedorf

Similar fights have erupted at some other migrant centres in Germany. A bigger brawl took place near Kassel, in central Germany, at the end of September.

In Berlin, Munich, Hamburg and elsewhere the authorities have erected tented camps for migrants - but with winter approaching they are deemed too basic as communal housing.

There is hardly any accommodation left in Hamburg for migrants, who are entering the city at a rate of about 500 daily, ARD television reports.

The Hamburg region's leftist government - a coalition of Greens, Social Democrats (SPD) and Die Linke - says the new law will be in force until March 2017.

Confiscation will only take place if the property owner refuses to hand it over willingly in exchange for compensation.

In the Brandenburg region, in eastern Germany, the authorities have halted the demolition of old social housing blocks. Instead they will be refurbished to provide 4,000 flats for migrants, the daily Die Zeit reports.

Meanwhile Franconia, in north Bavaria, plans to build cheap modular units to house migrants for 10 years, after which they will be rented out as social housing for locals.