NEW YORK — The good followed the bad for the stock market on Tuesday.

One day after logging its worst performance of the year, the stock market bounced back with its best day of 2014. The Standard & Poor’s 500 index climbed more than 1 percent and erased most of its loss from a day earlier.

Technology stocks led the gains as Wall Street analysts raised their assessments of Intel and electronics company Jabil Circuit.

A report on retail sales also boosted investor confidence. Excluding spending on autos, gas and building supplies, sales increased 0.7 percent in December, the Commerce Department reported Tuesday.

That was better than the increase of 0.4 percent forecast by economists.

While the rise in December sales was modest, it helped ease investors’ concerns about the health of the economy after a surprisingly weak jobs report was published on Friday.

“This is a preview of what 2014 will be like…it’s going to be more volatile than it was last year,” said Andres Garcia-Amaya, a global market strategist at JPMorgan Funds. “The market’s bouncing back and saying the world’s not ending, things are pointing in the right direction.”

The S&P 500 index gained 19.68 points, or 1.1 percent, to 1,838.88, its biggest gain since Dec. 18. It rose steadily throughout the day and finished close to its high on Tuesday.

The Dow Jones industrial average rose 115.92 points, or 0.7 percent, to close at 16,373.86, just below of its high of the day. The technology-heavy Nasdaq composite rose 69.71 points, or 1.7 percent, to 4,183.02.