Gold prices edged higher on Friday and were on track for their biggest monthly gain in five, as concerns of an economic slowdown arising from the coronavirus epidemic kept the safe-haven metal supported.

Spot gold rose 0.75% to $1,585.8 per ounce. The metal has gained 4% so far this month, on course for its best month since August. U.S. gold futures rose 0.1% to $1,590.8 an ounce.

The World Health Organization on Thursday declared the coronavirus outbreak a global emergency, however, it opposed restrictions on travel or trade with China and showed confidence that China could contain it.

"The virus and its potential to impact the global economy negatively is keeping gold supported," Saxo Bank analyst Ole Hansen said.

"However, the lack of fresh buying is keeping the metal from moving up even though uncertainties around coronavirus is affecting other markets like the equities."

The virus, which has claimed 213 lives so far in China and has spread to at least 22 countries, has brought a halt to many provinces in the world's second-largest economy with lockdowns, travel restrictions and closed businesses.

World share markets fought to regain their footing as investors clutched at hopes that China could contain the coronavirus.

"At this point, it (impact from the virus) is not something the Chinese economy can shrug off, there will be a hit to growth, the magnitude of which will be difficult to chisel out in detail for quite a while," said Ilya Spivak, a senior currency strategist at DailyFx.

Meanwhile, surveys showed steady Chinese factory activity and firm services this month, though this was likely before the virus took full hold.

"Wuhan fears should ensure that a break below $1,560 is very unlikely ahead of the weekend," Jeffrey Halley, senior market analyst at OANDA, said in a note.

In Europe, the United Kingdom will leave the European Union an hour before midnight.

Palladium was down 0.7% at $2,294. Prices were set to gain 18% this month, the best since November 2016, but were down 5.7% this week.

Silver rose 0.1% to $17.85 and but was down 1.3% for the week, the worst since the week ended Dec. 6. Platinum shed 0.8%, to $970.04, and was on track to decline 3.2% for the week, its steepest since early November.