LONDON (Reuters) - Gold prices drifted lower on Thursday, pressured by a firmer dollar as investors awaited signals on interest rates from central bankers meeting in Jackson Hole.
Losses were limited, however, after a threat by U.S. President Donald Trump to shut down the government unless he got funding for a border wall with Mexico.
Key to the direction of the market were funds holding huge long positions in Comex gold futures, said Ole Hansen, head of commodity strategy at Saxo Bank in Copenhagen.
"We've had two failed attempts at the upside this year which resulted in a flush out of longs, and the longer we stay here without breaking higher, the bigger the risk that these guys will start to get impatient," he said.
Gold failed in April and June to break through the top of its broad $1,200-$1,300 range this year.
"But at the same time, there's this threat to close down the U.S. government by Trump if he doesn't get his wall so that's providing some underlying support. It's well and truly wait and see."
Spot gold was down 0.1 percent at $1,288.91 an ounce by 1400 GMT, after gaining 0.4 percent in the previous session.
U.S. gold futures slipped 0.03 percent to $1,294.30 per ounce.
"The market is pricing in the Federal Reserve's actions at the Jackson Hole meeting and people are expecting some kind of tightening going on in that space," said Richard Xu, a fund manager at China's biggest gold exchange-traded fund, HuaAn Gold.
Markets were focused on an annual meeting of central bankers in Jackson Hole, Wyoming, starting on Thursday, where Federal Reserve Chair Janet Yellen and European Central Bank chief Mario Draghi are set to deliver speeches on Friday on the outlook for monetary policy and interest rates.
Gold is highly sensitive to rising U.S. interest rates, as these increase the opportunity cost of holding non-yielding bullion, while boosting the dollar, in which it is priced.
The dollar recovered on Thursday, helped by nerves over what message Fed policymakers will send from Jackson Hole and holding gains after U.S. jobless claims rose less than forecast.
Silver fell 0.3 percent to $16.97 an ounce, while platinum rose 0.5 percent to $980.70 an ounce.
Palladium added 0.2 percent to $934.40.
"With the palladium-platinum spread down to about $40, it's getting close to lows we witnessed back in June, when platinum had the latest run to the upside," Hansen said.
"Based on the spread relationship, palladium should struggle to perform, in the short term at least."
(Additional reporting by Apeksha Nair in Bengaluru; Editing by Dale Hudson)