U.S. stocks staged a late-day comeback on Thursday, boosted by economic comeback plays as the market rebounded from a two-day losing streak.

The S&P 500 closed 0.5% higher at 3,909.52, wiping out a 0.9% intraday loss. The Dow Jones Industrial Average gained 199.42 points, or 0.6%, to 32,619.48 after losing as much as 348 points. The Nasdaq Composite also eked out a 0.1% gain to close at 12,977.68 as some major technology stocks reserved losses. Tesla rose 1.6%, while Apple closed in the green.