You can say a lot of things about the stock market right now, but one thing's clear: It ain't cheap.

The S&P 500 (^GSPC -0.29%) trades at a price-to-earnings ratio of 28, and an even more expensive 37 on the CAPE ratio, a measure favored by Nobel-winning economist Robert Shiller that takes into account the last 10 years of earnings. JPMorgan Chase CEO Jamie Dimon recently described the stock market as "kind of inflated," and he's one of the few Wall Street titans with the credibility to move markets with just a few words.

However, while most of the market is more expensive than it was two years ago when the bull market started, there are some bargains still available. Here are two bargain stocks worth considering in 2025.

A sale banner across a store.

Image source: Getty Images.

1. Micron

Micron (MU -1.57%) hasn't gotten as much attention as some other chip stocks in the AI era, but the memory-chip specialist deserves a close look based on its current valuation and fundamentals.

The company is an integrated device manufacturer, meaning it both designs its chips and manufactures them. This makes it highly cyclical, as the semiconductor sector's supply-and-demand balance and inventory dynamics can shift quickly, making it prone to booms and busts. As the stock chart below shows, Micron has been through several cycles in the past decade, but the stock has trended higher over that time.

MU Chart

Data by YCharts.

As you can see, investors who were able to stomach the volatility and hold on over the last decade earned a handsome return.

These days, the semiconductor cycle is undoubtedly in an upswing, and so is Micron. Revenue jumped 84% in its fiscal 2025 first quarter, which ended in November, and it's clearly benefiting from the AI boom, as its data center revenue soared by 400% year over year and 40% sequentially.

The share of its revenue coming from its data center and networking segment topped 50% for the first time, reaching 55%. That was up from 20% in the quarter a year ago.

Any company that's growing the segment that provides the majority of its revenue by 400% on a year-over-year basis and 40% sequentially is an attractive proposition. But beyond that, the stock is surprisingly cheap, trading at a forward P/E of 16. The share price fell following its December earnings report, as guidance disappointed due to its customers reducing their inventories, but management expects a rebound in the second half of the year. Micron stock is now down about 30% from its peak last summer, offering an attractive discount.

Given the tailwinds Micron is enjoying from the AI trend, its breakout growth in the data center space, and its low valuation, the stock looks like a good buy for 2025.

2. Dollar General

Moving from semiconductors to discount retail, we can find another bargain stock in Dollar General (DG 0.63%).

With more than 20,000 stores, Dollar General is the largest retail banner in the U.S., and historically, its model of offering low-priced, small-pack consumer staples and some discount discretionary goods has been a success. The stock has been a big winner for most of its history.

However, last year, Dollar General's stock plunged as profits fell due to macroeconomic challenges, competition from Walmart, and internal weaknesses.

As a result, Dollar General now trades at a P/E ratio of 12, which is a great valuation if the company can rebound from last year's challenges. Its margins are suppressed, but that issue looks to be temporary, and the company continues to grow, in line with its plan to blanket the country -- and rural America in particular -- with its stores.

Management also has a turnaround plan, focusing on getting "back to basics," like reducing the number of out-of-stock items, ensuring its checkout areas are adequately manned, managing inventory appropriately, and streamlining its supply chain by closing temporary warehouses. It's also experimenting with delivery in a bid to compete with Walmart's convenient e-commerce offerings.

Those moves should help improve the company's margins, and it should also benefit from an eventual recovery in consumer spending as inflation cools and interest rates come down.

With a P/E of 12 and paying a dividend that yields 3% at the current share price, Dollar General's risk seems priced in, and there's a lot of upside for the stock if the company can get back to its previous profitability levels. This is a bargain worth putting in your shopping cart.