Costco Wholesale (COST 0.35%) has become one of the more notable retail success stories of the early 21st century. The retail giant has expanded to nearly every state and numerous countries across the world, finding success in places where other peers failed.

Admittedly, the stock's rich price-to-earnings (P/E) ratio of 36 makes it more expensive than all of its peers except Amazon. That may have prompted Warren Buffett's Berkshire Hathaway to exit its Costco position even though Buffett partner Charlie Munger sits on Costco's board.

Nonetheless, given its ability to grow in nearly every environment, investors should feel optimistic about Costco's long-term growth prospects. Here's why.

Recession resistance

Americans remain worried about the economy amid stubbornly high inflation and large-scale layoffs. Costco is not entirely invulnerable to economic conditions. However, with this retailer, such conditions usually slow instead of stop growth.

In the first two quarters of its fiscal 2023 (ended Feb. 12), Costco reported just under $110 billion in total revenue, a 7% increase from the first half of fiscal 2022. That lags the 16% yearly revenue growth in the first two quarters of 2022 but confirms Costco's ability to drive higher sales despite its challenges.

Indeed, Costco is one of the largest grocers in the country, and the fact that people need to eat regardless of the economy keeps this portion of its revenue stable. Still, Costco's low prices and ability to sell in bulk hold considerable appeal to consumers who are low on cash, thus driving more sales.

That growth also emphasizes another one of Costco's strong attributes: customer loyalty. Its customers renewed memberships at a rate of 93% in the U.S. and 91% worldwide in fiscal Q2, indicating a high level of satisfaction.

Admittedly, Costco's success is not a secret, and its stock is typically more expensive than most of its peers. But with continuing growth and intense customer loyalty, this unstoppable business is likely to maintain that premium valuation.

COST PE Ratio Chart

COST PE Ratio data by YCharts

Prospects for expansion

However, the most significant attribute investors may overlook is Costco's ability to expand. In the U.S., it owns 584 warehouses in 46 states. Despite those numbers, it is far from reaching saturation.

First, in many states, Costco only operates warehouses in large metros. For example, it has 33 locations in its home state of Washington, but only 30 in Florida, a state with nearly three times the population of Washington. That indicates potential in Florida and other states to add warehouses in midsize metro areas.

Additionally, it has begun to build Costco Business Centers which, as the name implies, serve businesses directly. With more than half of these locations west of the Rockies, the company can add more Business Centers for years to come.

Still, the most significant growth may come from the potential to add to its 265 warehouses located in 13 foreign countries across four continents. Costco has appeared to cross cultural barriers successfully in these countries, a factor that has stymied most of its competitors.

Target failed in Canada and to this day does not operate any stores outside of the U.S. Walmart experienced embarrassing failures in places like Germany and Brazil, and it operates fewer than 400 stores in the massive China market despite being an early entry into that market. Likewise, Home Depot has not ventured outside of North America since pulling out of China and South America years ago.

The international failures of Costco's competitors leave the long-term expansion prospects in doubt for these companies. Since Costco does not have this worry, it removes one significant doubt that could hamper the stock's growth.

Consider Costco

Considering Costco's success in nearly every environment, it will likely beat the market over the next five years. Indeed, growth levels slowed in recent quarters, and the consumer staples stock's high P/E ratio may deter value investors.

But despite its size, Costco is years away from saturation in the U.S. It could also expand for decades across the world as it transcends the cultural barriers that deterred competitors. Those factors and its enduring ability for growth should continue to attract interest in Costco stock.