In second paragraph corrects direction of close to read "up from" instead of "down from" (Recasts, updates prices, market activity to U.S. close; adds second byline, dateline, previously LONDON)
By Frank Tang and Atul Prakash
NEW YORK/LONDON, March 27 (Reuters) - Gold ended higher on Thursday, near its one-week peak as a late rally of energy prices offset a stronger dollar.
Analysts said sentiment was positive. They said gold, viewed as a hedge against oil-led inflation, may retest the $1,000-mark soon on support from strong oil prices that jumped after an oil pipeline explosion in Iraq.
Spot gold <XAU=> hit a high of $954.50 an ounce before ending at $951.80/952.60 by New York's last quote at 2:15 p.m. EDT (1815 GMT), up from $949.00/949.80 in New York on Wednesday. It hit a lifetime high of $1,030.80 an ounce on March 17.
"On the one hand you have high oil prices supporting gold and on the other hand you have got quite a lot of news about the dollar gaining some ground against the euro and other mixed economic data that has taken some shine off gold," metals analyst Robin Bhar at UBS said.
Oil surged above $108 a barrel after saboteurs blew up one of Iraq's two main export pipelines, a Southern Oil Company official told Reuters, adding the country was likely to lose about a third of crude exported through Basra. U.S. crude futures <CLc1> settled up $1.68 to $107.58 a barrel.
The dollar rallied after a government report showed the U.S. economy grew in line with market expectations in the fourth quarter. Demand for the U.S. currency ahead of the end of the first quarter gave the dollar some support after two days of steep losses. That put pressure on gold.
A weaker dollar makes gold cheaper for holders of other currencies and often lifts bullion demand.
"But the market is consolidating, waiting for new direction to come through, and gold would always thrive as a safe heaven and that has not gone away as a factor and it will propel gold again higher in due course," Bhar said.
OUTLOOK POSITIVE
Analysts said commodity investors were growing more confident again after a broad sell-off last week knocked gold to a one-month low of around $904 an ounce.
"We are pretty bullish on gold over the medium-term. Most likely, we are going to see some short-term stability," said Dan Smith, metals analyst at Standard Chartered Bank.
Premiums for gold bars rose to their highest in nine months in Singapore this week. Demand from jewelers stirred trade in Hong Kong, while purchases from investors in Asia resurfaced after last week's sell-off.
Bill O'Neill, managing partner of LOGIC Advisors in Upper Saddle River in New Jersey, said gold should be boosted by recovering physical buying and brisk safe-haven demand.
"There is no question that there's been some slowdown in physical demand from India. That's going to prove to be temporary, and people will get used to the higher prices," O'Neill said.
In other markets, the active U.S. gold contract <GCJ8> for April delivery on the COMEX division of the New York Mercantile Exchange settled down 40 cents to $948.80 an ounce.
Spot platinum <XPT=> ended at a high of $2,023/2,033 an ounce against $1,990/2,000 late in New York on Wednesday.
Palladium <XPD=> prices fell to $445/460 an ounce from its previous finish of $453/458. Silver <XAG=> was at $18.49/18.54 an ounce after rising to a one-week high of $18.61 an ounce, versus $18.35/18.40 late in the U.S. market on Wednesday. (Additional reporting by Bate Felix in London; Editing by David Gregorio)