Gold rose on Thursday as the dollar edged away from 2018 highs after weaker than forecast U.S. inflation data and as simmering tensions between the United States and Iran lent the precious metal further support.
The dollar slipped from a 4-1/2 month peak after U.S. data showed the consumer price index rose 0.2 percent in April versus forecasts for a 0.3 percent increase. A weaker dollar makes dollar-priced gold cheaper for non-U.S. investors.
Also helping gold, viewed as a safe-haven investment, was U.S. President Donald Trump's move on Tuesday to withdraw from a nuclear accord with Iran, raising the risk of conlfict in the Middle East.
Israel said on Thursday that it had attacked nearly all of Iran's military infrastructure in Syria after Tehran fired rockets at Israeli-held territory for the first time.
"We've seen a (dollar rally) in the last few weeks, but actually gold hasn't gone down as far as you might think, so political tensions are helping," said Macquarie commodities strategist Matthew Turner.
Turner added, however, that the dollar was the main driver for gold and he expects the precious metal to come under pressure in the near term, with the dollar extending its rally.
Spot gold rose by 0.6 percent to $1,319.66 an ounce by 1237 GMT. U.S. gold futures for June delivery were also up 0.6 percent at $1,321.40.
Capping the precious metal's gains was evidence of risk appetite, with global equities hitting a three-week high as rising oil prices gave energy companies a shot in the arm that countered the effects of increased political uncertainty.
North American gold-backed exchange-traded funds registered inflows in April at their highest level since September 2017, with safe-haven purchases ushered in by a trade stand-off between the United States and China, Syria tensions and worries about possible U.S. sanctions on Russia.
Spot gold looks neutral in a range of $1,302-$1,317 an ounce, said Reuters technical analyst Wang Tao.
In other precious metals, silver gained 0.6 percent to $16.59 an ounce after hitting a two-week high at $16.62 in the previous session.
Platinum rose 0.9 percent to $918.20 while palladium edged up by 0.1 percent to $975.72.