Stocks staged a massive reversal on Friday after President Donald Trump said conversations with China over trade will continue and his relationship with President Xi Jinping remains strong.

The Dow Jones Industrial Average finished the day 114.01 points higher at 25,942.37, roaring back from a 358-point loss earlier in the session that came in the wake of a tariff increase by the U.S. effective just after midnight. The snapped a four-day losing streak, eking out a 0.37% gain at 2,881.40. The Nasdaq Composite ended the day slightly higher at 7,916.94 after stocks rallied from their lows.

Stocks hit session highs after Trump's late Friday tweet and closed near those levels. The president also noted that the trade talks with China were "candid and constructive." Trump said the new tariffs on $200 billion worth of Chinese goods "may or may not be removed" in the future.

tweet

tweet

Major averages began paring some of their losses midday after Treasury Secretary Steven Mnuchin said China trade talks had ended for the day and were "constructive." Chinese Vice Premier Liu He also said the talks went "fairly well," according to reports.

Despite Trump's tweet that conversations with China would continue, Mnuchin later told CNBC no official talks are planned as of now.

"It's really likely that it gets resolved and if it does, you've got to believe we'd be back at highs very quickly," said Jim Paulsen, chief investment strategist at The Leuthold Group. "Because around it, there's a good story – a lot of green shoots, rates are staying low and better earnings."

While a Trump tweet pushed stocks higher into the close, it was an earlier tweet by the president that helped send the market to its low of the session. Trump said in an early morning tweet storm there's "absolutely no rush" on a trade agreement with China. The comments came after he slapped higher tariffs — from 10% to 25% — on $200 billion worth of Chinese goods. Apple, which has growing China revenue exposure for the iPhone, was still down 1.4% on Friday, bringing its losses for the week to nearly 7%.

Tweet

The president added that tariffs will make the United States "much stronger," and "China shouldn't renegotiate deals with the U.S. at the last minute."

Trump's "bark is worse than his bite a lot of the times," said Arian Vojdani, investment strategist at MV Financial. "We might see him try to come down a little hard, but ultimately people really don't think we are going to see that drastic trade war play out ... The administration is very keen on markets and they don't want to see pain."

Companies that are hinging on a trade resolution remained under some pressure despite the day's reversal. Chipmakers took a big hit on fears of an escalated trade war as the VanEck Vectors Semiconductor ETF posted its worst week of the year, down almost 6%.

Ride-hailing giant Uber began trading on the New York Stock Exchange Friday at $42 per share, after pricing at $45 per share. The stock finished the day nearly 8% lower.

Trump started this week's market turmoil with two tweets Sunday evening, threatening to hike tariffs on more Chinese exports as Beijing tried to renegotiate.

Despite Friday's gain, the S&P 500 still suffered its worst week of the year, losing nearly 2.2%.

Some on Wall Street believe investors should be ready for the trade battle to drag on for a long time.

"We continue to expect the two sides to reach a trade deal eventually, but this is unlikely to happen in the short term as the war is not painful enough for either side," Zhiwei Zhang, Deutsche Bank's chief Asia economist said in a note on Friday.

— CNBC's Eustance Huang and Kate Rooney contributed to this report.