The Dow rose almost half a percent. The S&P 500 ended four tenths of a percent higher, while the Nasdaq rose six tenths of a percent.

Monday's move higher extended gains from last week when signs that U.S. inflation may have peaked in July increased investor confidence that a bull market could be under way.

But Nancy Daoud, private wealth advisor at Ameriprise Financial, said she expects more pain ahead.

"Well, there's a lot of speculation that, is this, is it over? Or are we, is this just a bear market rally? Unfortunately, nobody really knows the answer to that. But I don't feel that we're out of the woods yet. This may be just a short term adjustment, but the real adjustment will occur when the Feds really curb the inflation numbers. That's our biggest problem now is inflation."

Shares of mega-caps rose, with Tesla posting a 3% gain, while Apple and Microsoft helped boost the S&P 500 and Nasdaq.

Shares of energy companies fell on Monday following the bad news out of China, the world's largest importer of crude oil.

Mining stocks also fell as industrial metals sold off following the Chinese economic data.

And shares of Disney rose after billionaire investor Daniel Loeb said his hedge fund had re-invested in the media giant and will push for changes there after his firm liquidated its position in the company in the first quarter.