With its trailing-12-month net revenue of $230.1 billion, making it the world's third-largest retailer, there's no denying Costco Wholesale's (COST -0.82%) dominance in the world of shopping. It's a safe assumption that many people place Costco at the top of their lists when it comes to getting all of their needs, whether it's food, gas, appliances, or really any other merchandise category. 

But the internet age has presented a challenge that investors are certainly aware of, and that's the threat of e-commerce, particularly from the likes of a giant like Amazon (NASDAQ: AMZN). Should Costco shareholders worry about the tech juggernaut? 

I don't think so. Here's why.  

What does Costco really sell? 

Costco has had a long history of incredible success by providing its members -- 123 million cardholders worldwide -- with the highest-quality merchandise at the lowest prices around. Costco focuses on a smaller number of national and private-label brands. Because it can purchase inventory in such massive quantities, prices are kept low. 

But for the past couple of decades, brick-and-mortar retailers have always had to consider the 800-pound gorilla in the room, stomping toward them. And that is Amazon.

According to Statista, the tech behemoth commanded more than two-thirds of the e-commerce market in the U.S. as of June 2022. And the company's popular Prime membership counts more than 200 million subscribers, providing free shipping for delivery orders, among a host of other features. It's evident that Amazon's strengths are offering a wide selection, speed, and convenience, areas that even Costco doesn't dare to compete with directly. 

Costco has clearly still been able to thrive even at a time when Amazon has ascended to new heights. Net sales in fiscal 2022 were 129% higher than they were in fiscal 2012. And this has to do with the effectiveness of its 848 warehouses.

The company's main objective is to encourage customers to browse through the aisles and take advantage of various deals, sometimes spending more than they had originally planned for. And this makes the physical shopping experience at Costco a feature, not a bug. 

For what it's worth, Costco is investing in its e-commerce capabilities, partnering with Instacart for same-day grocery delivery. And in 2020, it acquired Innovel for $1 billion to expand the company's capabilities to deliver big and bulky products.

While these provide more options for consumers, during fiscal 2022, e-commerce revenue accounted for only 7% of total net sales. And e-commerce comparable sales were down 9.6% in the latest fiscal quarter. 

Consequently, it's obvious that Costco's physical stores will undoubtedly still be key to its operations decades from now. Even during a time like the pandemic, when consumer mobility was restricted and people increasingly turned to online shopping, its value proposition as a one-stop destination to get all your household needs was on full display. To hammer home this point, consider that in fiscal 2021 and fiscal 2022, same-store sales were up 16% and 14.4%, respectively. 

I don't think this consumer behavior will change anytime soon, and it's why Costco has one of the most durable economic moats around. The company sells a fantastic shopping experience first and foremost, featuring low-priced items, great customer service, and treasure hunts.

While online shopping has further penetrated the retail landscape, it still only accounted for 14.7% of overall sales in the U.S. in the last three months of 2022. No one knows how high this figure will go, but it's certain that there will always be a need for Costco's physical locations. 

Investors who have a sizable sum to put to work should probably wait for a pullback before buying shares, which trade at a price-to-earnings multiple of 36 today, about twice as expensive as the broader S&P 500 index. And for those who employ dollar-cost averaging, investing capital at periodic intervals, there's no reason to wait for a better entry price.

Costco will continue to perform well as a business, despite the risk of a recession in the near term. Therefore, I see nothing wrong with being a constant buyer of the stock over time, accumulating shares up to an allocation that you are comfortable with. Your portfolio will likely be rewarded with the addition of such a resilient enterprise.