Walmart (WMT 0.94%) and Costco Wholesale (COST 0.61%) are two iconic retailers that have shown they can do well regardless of economic conditions. Walmart's low prices have attracted high-income shoppers looking to stretch their budgets, enabling the business to do well even in tough times. And while Costco often leaves shoppers spending more than they planned, its bargain-hunting experience has been highly successful.
Over the past five years, their returns have been comparable, with Walmart rising by around 190% and Costco's stock up 175%. Both have surged past the S&P 500, which has rallied at a more modest rate of 82% during that period. This year, Walmart's valuation hit $1 trillion in market cap, while Costco's valuation is around $450 billion.
In terms of earnings, however, both of their valuations may be a bit stretched, as neither stock looks particularly cheap. But if you're planning to buy and hold for the long term, which one could be a better addition to your portfolio today?
Image source: Getty Images.
Costco's growth rate has typically been stronger
These retail stocks are generating just single-digit growth these days, but their performance has been reasonably strong given the headwinds and challenges consumers are facing amid rising prices. What's notable from the chart below, however, is that Costco's growth rate remains a fair bit higher than Walmart's, and when there's been greater appetite for discretionary purchases, the difference has been even more significant.
WMT vs Costco (Quarterly YoY Growth) data by YCharts
Walmart's business centers more around essentials and groceries. While Costco also sells groceries, its bargain-hunting experience often entices shoppers to spend a bit more, and the results show that's been highly effective. Both businesses may continue to do well this year as shoppers seek savings amid rising prices. Costco's cheap gas prices are also likely to lead to greater foot traffic, which may, in turn, drive more in-store sales.

NASDAQ: WMT
Key Data Points
Walmart's recent rally has pushed its valuation nearly as high as Costco's
Over the past 12 months, Costco's stock has been flat, while Walmart's shares have risen 35%. In the process, that has made their valuations much more comparable; previously, Costco was trading at a far higher price-to-earnings multiple than Walmart. Now, however, that gap has shrunk significantly.
WMT vs COST on PE Ratio data by YCharts
A year ago, the conclusion would have been evident: Walmart was clearly the cheaper stock. But now, with one stock trading at 53 times earnings and another at nearly 48, there's a difference, though not massive enough to drastically tip the scales in favor of one over the other. Either way you look at it, you're paying a hefty premium for both stocks, and it really comes down to which one may be more worthy of it.

NASDAQ: COST
Key Data Points
Why I'd give the edge to Costco's stock today
There are many similarities between the two stocks, but the big difference for me is that Walmart is more of a grocery and defensive play than Costco, which may benefit more from stronger economic conditions and heightened consumer spending. Paying around 50 times earnings for either stock is hard to stomach, but with Costco, I believe there's far more growth potential.
Not only can Costco's growth rate rise significantly if discretionary spending is on the rise, but its footprint is also smaller; it can more easily pick its spots as to where in the country or the world, for that matter, to expand into. Its large warehouses are often packed and attract a lot of attention. Furthermore, its website and e-commerce business may be a big source of future growth. Walmart, on the other hand, arguably has a much stronger online presence as it competes head-on with e-commerce giant Amazon.
Costco looks better positioned to grow in the long run, which makes its high valuation much more tenable, and that's why I believe it's the better buy at this stage.







