Stocks rose higher on Wednesday ahead of two key inflation reports scheduled for release later this week, as investors remain optimistic towards the U.S. economy's recovery. The Dow Jones Industrial Average climbed over 170 points, while the S&P 500 Index and Nasdaq Composite rose roughly 0.6% and 0.8%, respectively.

Here's how the market settled on Wednesday:

S&P 500 Index (SPY  ): +0.57% or +26.95 points to 4,783.45

Dow Jones Industrial Average (DIA  ): +0.45% or +170.57 points to 37,695.73

Nasdaq Composite Index (QQQ  ): +0.75% or +111.94 points to 14,969.65

Making headlines, Wells Fargo analyst Christopher Harvey wrote in a Wednesday note that investors should be cautious ahead of the fourth-quarter earnings season, offering a cautious outlook due to historical seasonal weakness for stocks throughout the January-February months.

"We are cautious entering peak earnings season given: (1) the expected 'management' of 2024 guidance, perhaps driven by weaker pricing/volume trends; and (2) the negative post-earnings returns for the 21 'off-season' SPX firms that have reported," Harvey wrote.

Earnings reports from major stocks including Bank of America (BAC  ), JPMorgan Chase (JPM  ), UnitedHealth Group (UHG  ), BlackRock (BLK  ) and Delta Air Lines (DAL  ) are all slated for release later this week.

Also in major Wednesday news, Amazon (AMZN  ) announced it is laying off hundreds of employees across its Prime video and MGM Studios businesses, as well as 500 positions cut from its Twitch livestreaming unit, in effort to "prioritize our investments for the long-term success of our business," said Mike Hopkins, senior vice president of Prime Video and Amazon Studios, in an employee memo viewed by CNBC.

"Throughout the past year, we've looked at nearly every aspect of our business with an eye towards improving our ability to deliver even more breakthrough movies, TV shows, and live sports in a personalized, easy to use entertainment experience for our global customers," Hopkins wrote in the memo, quoted by CNBC. "As a result, we've identified opportunities to reduce or discontinue investments in certain areas while increasing our investment and focus on content and product initiatives that deliver the most impact. As a result of these decisions, we will be eliminating several hundred roles across the Prime Video and Amazon MGM Studios organization."

On the earnings front, WD-40 (WDFC  ) shares jumped more than 15% after the consumer household goods maker reported better-than-expected fiscal first quarter results. "We have started fiscal year 2024 firing on all cylinders, with significant volume-related sales growth across all three trade blocs," CEO Steve Brass said in a statement.

In single-stock news, Hewlett Packard Enterprise (HPE  ) announced after market close on Tuesday that it will acquire Juniper Networks (JNPR  ) in an all-cash deal for $40 a share, or about $14 billion. The news follows a report from The Wall Street Journal that HPE was in "advanced talks" to purchase the networking products company, in a likely challenge to Cisco Systems (CSCO  ).

Lennar Corp (LEN  ) shares climbed higher on Wednesday after the homebuilding increased its annual dividend to $2 per share from $1.50 per share, and it's board has approved a $5 billion stock buyback program.

For Thursday, market participants will react to December's consumer price index (CPI) reading due out in the morning.