In a market teeming with negative sentiment, Costco (COST -0.12%) continues to rally. The retail juggernaut has climbed 54% in the past year, strikingly higher than the S&P 500's 5% gain in the same time frame. The company's long-term performance has been stellar as well -- Costco has returned a walloping 272% to shareholders over a five-year span, implying an average annualized return of 54%. 

Given the ambiguity surrounding the stock market today, Costco may appear to be a worthy investment opportunity. After all, the company is as consistent as they come and boasts a superb financial track record. Although I don't know if Costco shares will continue in their upward trend moving forward, I am certain that the company isn't flawless.

With that in mind, let's explore three potential downsides all investors should be aware of before buying Costco stock today.

Person with arms crossed, wearing an apron and standing outside a shop.

Image source: Getty Images.

1. Growth is decelerating

Costco had a tremendous outing in 2021. The membership-only retailer expanded both its top and bottom line by 20% year over year, up to $195.9 billion and $11.09 per share, respectively. The positive momentum has carried over into 2022: Wall Street analysts are modeling sales and earnings of $221.8 billion and $13.11 per share, respectively, this upcoming year, representing annual increases of 13% and 18%.

Considering Costco's behemoth size, investors can't expect high levels of growth forever. Wall Street analysts forecast the company will generate $276.2 billion in revenue and $17.81 in earnings per share by 2025, indicating annualized growth rates of only 7% and 10% from 2021 levels, respectively. This isn't awful growth, but it surely doesn't seem ideal when taking into account the company's all-time high valuation.

2. Unattractive valuation

Historically, Costco has traded at a premium relative to its industry peers. The company's membership model, top-notch private label, and unique ability to sell items at unbeatable prices have compelled investors to feel comfortable paying a steeper price for the stock in the past.

Today, Costco is trading at 46 times earnings. This is well above competitors BJ's Wholesale, Walmart, and Target, which currently carry price-to-earnings multiples of 22, 32, and 17, respectively. In fact, the median price-to-earnings (P/E) ratio of the four retailers is 27, meaning Costco is trading above a 50% premium to its close industry peers. 

COST PE Ratio Chart

COST PE Ratio data by YCharts.

Even if Costco has historically enjoyed a steeper valuation than its competition, the company's latest P/E multiple appears dreadfully high. Costco's five-year average P/E ratio is 36, or 25% below today's levels. So even if you're willing to pay a loftier price for the retail titan, the company's current valuation looks too expensive to justify at this time.

3. The threat of e-commerce

It's soundly understood by now that we're witnessing a paradigm shift toward e-commerce in the retail sector. Costco is well-known for its in-store shopping experience, so it's possible that e-commerce alternatives could eat away at the company's sales in the long run. In 2021, e-commerce revenue made up only 7% of Costco's total top line. Although it's important to preserve its core business, Costco must work to continuously improve its e-commerce sales in the coming years.

E-commerce revenue also serves as a way to spark growth as store openings unwind over time. Inevitably, Costco will reach a point where it can no longer resort to new locations to drive additional growth. And given that the company's e-commerce segment currently represents less than 10% of total sales, Costco's untapped potential in this arena is absolutely massive.

I'd wait to buy Costco

Costco is a world-beater in the retail space, but I wouldn't suggest buying the stock today. With growth projected to unwind in the future and a valuation at record highs, investors aren't presented an optimal buying opportunity at the moment. The company's unwillingness to adopt e-commerce as rapidly as the remainder of the industry is also something to closely keep an eye on moving forward. I think Costco will continue to perform well over the long run, but it wouldn't be unwise to hold off on buying the stock until it experiences a pullback.

In short, Costco is a great company, but it's not a great investment in today's market.