NEW YORK (Reuters) - U.S. Treasury and gold prices rose while the Japanese yen strengthened on Friday as a fresh exchange of barbs between North Korea and the United States fueled geopolitical concerns.

Passersby walk past a TV screen reporting news about North Korea's missile launch in Tokyo, Japan September 15, 2017. REUTERS/Issei Kato

North Korea said it might test a hydrogen bomb over the Pacific Ocean, in response to U.S. President Donald Trump’s threat on Tuesday to destroy the reclusive country.

The aversion to risk drove investors into assets considered safer during times of geopolitical turmoil, like the yen, bonds and gold, though the U.S. benchmark S&P 500 stock index reversed mild losses late in the day to end higher.

“Increasing tensions with North Korea is putting a little bit of selling pressure on the dollar, especially against the Japanese yen,” said Omer Esiner, chief market analyst at Commonwealth Foreign Exchange in Washington. “Keep in mind, the yen is bouncing off of about a two-month low.”

The U.S. dollar had scaled a two-month peak of 112.71 against the yen on Thursday, boosted by the Federal Reserve signaling this week that it was still on track to raise U.S. interest rates by the end of the year, and after the Bank of Japan maintained its bond-buying pledge.

The yen strengthened 0.44 percent versus the greenback to 112.00 per dollar JPY=, while sterling GBP= was last trading at $1.3484, down 0.69 percent on the day.

Sterling slipped and Britain’s main stock index climbed after Prime Minister Theresa May laid out plans for the country’s exit from the European Union.

May called for Britain to stay in the EU's single market during a roughly two-year transition out of the EU. The FTSE 100 stock index .FTSE rose 0.6 percent.

TREASURY PRICES UP

U.S. Treasury prices gained on concerns about conflict with North Korea. Benchmark 10-year notes US10YT=RR rose 7/32 in price to yield 2.2534 percent, from 2.278 percent late on Thursday.

Gold recovered from a four-week low in the previous session. Spot gold XAU= added 0.4 percent to $1,296.56 an ounce.

In U.S. stocks, investor focus on Washington’s latest healthcare legislation proposal and gains in energy shares overshadowed concern over geopolitical tensions.

Shares of health insurers cut losses and some ended higher after U.S. Senator John McCain said he opposes the latest plan to replace President Barack Obama’s healthcare law.

The energy index .SPNY was up 0.5 percent, following gains in oil prices. Also, the Russell 2000 index .RUT closed at a record high.

The Dow Jones Industrial Average .DJI fell 9.64 points, or 0.04 percent, to end at 22,349.59, the S&P 500 .SPX gained 1.62 points, or 0.06 percent, to 2,502.22 and the Nasdaq Composite .IXIC added 4.23 points, or 0.07 percent, to 6,426.92.

The pan-European FTSEurofirst 300 index .FTEU3 rose 0.08 percent and MSCI's gauge of stocks across the globe .MIWD00000PUS gained 0.13 percent.

Helping support the gains in Europe, euro zone businesses ended the third quarter with much stronger growth than predicted, adding to evidence of the region’s new-found dynamism which has spurred strong inflows into European equities this year.

Oil prices rose as major producers meeting in Vienna said they may wait until January before deciding whether to extend output curbs beyond the first quarter.

Brent crude LCOc1 rose 43 cents, or 0.8 percent, to settle at $56.86 a barrel, while U.S. crude CLc1 settled at $50.66, up 11 cents or 0.2 percent, within a few cents of its May peak.

For Reuters Live Markets blog on European and UK stock markets see reuters://realtime/verb=Open/url=http://emea1.apps.cp.extranet.thomsonreuters.biz/cms/?pageId=livemarkets