Stocks rose on Tuesday as strong earnings and encouraging inflation data pushed the S&P 500 to its best January since 2019.

The Dow Jones Industrial Average rose 368.95 points, or 1.09%, to 34,086.04. The S&P 500 gained 1.46% to 4,076.60. The Nasdaq Composite added 1.67% to 11,584.55, notching its best January since 2001.

Traders assessed how some of the largest firms are faring amid high inflation and fears of slowing consumer spending. General Motors shares jumped about 8.4% after the auto manufacturer posted strong earningsPulteGroup shares surged 9.4% after the homebuilder reported better-than-expected earnings. Shares of Exxon Mobil also rose nearly 2.2% following earnings.

Investors on Tuesday got bullish news on the inflation front before the Federal Reserve’s latest decision on interest rates. The employment cost index, which is an important measure of wages eyed by the Fed, showed compensation increased by 1% in the fourth quarter. It was below the 1.1% estimate from Dow Jones. Traders widely expect a quarter-point increase in rates by the Fed, but they are hoping softening inflation will cause Chairman Jerome Powell to signal a pause in tightening in the near future.

Stocks have had a stellar start to 2023. The S&P 500 and Dow gained 6.2% and 2.8% in January in their third positive month in four. The Nasdaq Composite added 10.7% this month for its best monthly performance since July.

A solid January could be a good sign for the market, and potentially foreshadow a continued uptick in the months that follow. Of the five instances in which the S&P gained more than 5% in January after a negative year, the benchmark index rose 30% for the year on average, said Carson Group’s Ryan Detrick in a tweet.

“We’re seeing all of these historical major drivers of the market starting to all point in a direction that we think would be supportive of equity market gains over the next few months,” AXS Investments CEO Greg Bassuk said.