Fed Chairman Jerome Powell cited a labor market that does not seem to be overly tight in advocating staying the course on rate hikes.

The S&P 500 snapped a three-session losing streak, while the Nasdaq posted a record high close, boosted by gains in Facebook Inc and Microsoft Inc.

Shares in Boeing Co, which has acted as a proxy for trade fears because it is the single largest U.S. exporter to China, rose 0.5 percent after six straight declines. The planemaker said on Wednesday it was confident that a new mid-market jet could enter service in 2025.

"Part of it might be people were selling stocks the past couple of days in order of where they see tariff priority," said JJ Kinahan, chief market strategist at TD Ameritrade in Chicago.

The Dow Jones Industrial Average ended down slightly, a day after it erased its year-to-date gains amid President Donald Trump's latest tariff threats against Chinese goods.

The Dow Jones Industrial Average fell 42.41 points, or 0.17 percent, to 24,657.8, the S&P 500 gained 4.73 points, or 0.17 percent, to 2,767.32 and the Nasdaq Composite added 55.93 points, or 0.72 percent, to 7,781.52.

The pan-European FTSEurofirst 300 index <.FTEU3> rose 0.31 percent and MSCI's gauge of stocks across the globe <.MIWD00000PUS> gained 0.35 percent.

In the U.S. Treasury market, Powell's comments on rate hikes boosted yields.

A slew of corporate bond supply also helped drive the sell-off in Treasuries, pushing yields higher, analysts said.

Benchmark 10-year notes last fell 12/32 in price to yield 2.937 percent, from 2.893 percent late on Tuesday. Before Powell's remarks, U.S. yields had been little changed.

The U.S. dollar was steady, near an 11-month peak against a basket of major currencies, as China's signal of tolerance of a stronger yuan offset anxiety about the global trade dispute.

Before Wednesday's market open, the People's Bank of China cut the yuan's midpoint rate to 6.4586 per dollar, the weakest since Jan. 12 and much stronger than market models had suggested.

In U.S. afternoon trading, an index that tracks the dollar against the euro, yen, sterling and three other currencies <.DXY> was little changed at 95.090, after touching an 11-month peak of 95.299 earlier.

In commodities markets, copper prices eased again after an inventory rise highlighted healthy supplies, extending declines from Tuesday tied to trade war worries.

Copper lost 0.36 percent to $6,815.50 a ton.

Oil prices were mixed, with U.S. crude futures supported by a drop in domestic inventories.

U.S. crude rose $1.15 to settle at $66.22 a barrel, Brent fell 34 cents to $74.74.

(Additional reporting by Richard Leong, Stephanie Kelly, Gertrude Chavez-Dreyfuss and Chuck Mikolajczak in New York, Medha Singh in Bengaluru, Eric Onstad, Sujata Rao, Dhara Ranasinghe and Marc Jones in London and Andrew Galbraith in Shanghai; Editing by Lisa Shumaker and Leslie Adler)

By Caroline Valetkevitch