Gold prices hit record highs on Wednesday, as investors grew anxious about a tight U.S. presidential race and loaded up on safe-haven investments, while silver traded close to its highest in 12 years.

Spot gold gained 0.1% to $2,750.87 per ounce as of 0951 GMT after hitting a record high of $2,758.37 earlier in the session. U.S. gold futures edged 0.2% higher to $2,765.00.

"It's the uncertainty related to the U.S. election and rising debt burden in the U.S. They have to issue billions of dollars of debt as well just ahead of the election into a relatively thin and nervous market," said Ole Hansen, head of commodity strategy at Saxo Bank.

"The risk of additional spending raising the debt burden even more is what's driving this safe-haven demand into investment metals right now."

Democratic U.S. Vice President Kamala Harris held a marginal 46% to 43% lead over Republican former President Donald Trump, a new Reuters/Ipsos poll found.

Economic uncertainty and geopolitical tensions boost non-yielding bullion, which has hit multiple record highs and surged over 33% so far this year to become one of the best-performing assets of 2024.

Gold got a boost after the U.S. Federal Reserve initiated its cycle of rate reductions last month with a significant 50-basis-point cut.

The odds of a similar move by the Fed in November have faded entirely, but traders see an 89% chance of a quarter-basis-point cut, the CME FedWatch tool showed.

Spot silver fell 0.7% to $34.59 per ounce after hitting its highest since late 2012 at $34.87 in the previous session.

"The gold/silver ratio, currently standing at around 80, means silver tends to benefit as a natural consequence of gold's push into new territory on the upside," Kinesis Money said in a note.

Silver's physical shortages also provide strong support for the metal, said Michael Langford, chief investment officer at Scorpion Minerals.

Platinum rose 0.7% to $1,035.95 and palladium dropped 0.4% to $1,069.55.

(Reporting by Anushree Mukherjee in Bengaluru, additional reporting by Swati Verma; Editing by Maju Samuel)