can ship books, furniture, and clothing across the Pacific Ocean in what seems to be a blink of an eye. But when it comes to delivering fresh groceries to your doorstep, the e-commerce giant's logistical prowess falters.

That's because the long journey of, say, an avocado from Mexico gets progressively harder the closer it gets to the final buyer. It's more costly and time consuming to deliver individual pieces of fruit to many customers. The hurdle, which has long vexed online retailers and is one of the chief reasons the grocery business is notorious for its low profit margins, is known in the logistics industry as the "last mile."

By acquiring Whole Foods, Amazon is buying not just an established, upscale supermarket brand, but also a vast distribution network of warehouses and more than 460 stores worldwide — replete with back rooms and cold storage — in some of the most affluent zip codes in America. That's a significant boost in numbers for the Seattle company, which currently operates fewer than 100 distribution centers in the U.S.

More hubs mean quicker and fresher delivery, which will bolster Amazon's existing grocery delivery service, AmazonFresh. The service, which is offered to the company's subscription Prime members for a monthly fee of $14.99, is available only in about 20 U.S. cities. While the bid for Whole Foods may not bridge Amazon's "last mile," it certainly brings it closer, experts say.

In the United States, "this adds 440 refrigerated warehouses within 10 miles of probably 80 percent of the population," said Michael Pachter, an analyst for Wedbush Securities. "More importantly, it puts refrigerated distribution within 10 miles of probably 95 percent of Prime members."

The merger of the two companies means Amazon can vertically integrate a business it has dabbled in since 2007, when it first offered grocery delivery in Mercer Island, Wash. That's a blow to such rivals as Target and Wal-Mart, which boasted their physical existence as one thing they had over Amazon. The stores allow people to try on clothing before buying, still one of the biggest hang-ups about online fashion, and they allow shoppers to choose the groceries they want, lest there be a bruised apple in their order.

Those big-box competitors were already disadvantaged by Amazon's captive audience, an estimated 80 million Prime members, who could theoretically order groceries online or task Alexa, Amazon's virtual assistant, to prepare a delivery or arrange for a pickup at the nearest Whole Foods.

The deal could also make competing delivery services superfluous. Why pay for food delivery elsewhere if Amazon is cheaper and easier?

It's a natural progression for Amazon, said Brendan Witcher, a retail analyst at Forrester. The company disrupted retail by offering lower prices. Now it's focusing on "logistics and fulfillment and the ability to get what you want when you want it," Witcher said.

To that end, Amazon is encroaching on territory long dominated by the likes of UPS, FedEx, and the U.S. Postal Service. In the last two years, it has leased 20 Boeing 767 air cargo jets from Atlas Air Worldwide Holdings, won shipping licenses that allow it to pay for containers at wholesale rates and rent them out for more expensive retail rates, and added thousands of long-haul trucks emblazoned with the Amazon logo.

Jeff Bezos, Amazon's founder and chief executive, said his company wasn't looking to replace legacy supply-chain companies. Instead, Amazon is adding its own logistics network because it simply can't have enough — not surprising, considering that the company was responsible for 43 percent of all online sales in the U.S. last year.

"We will take all the capacity that the U.S. Postal Service can give us and that UPS can give us and we still need to supplement it. So we're not cutting back. We're growing our business with UPS. We're growing our business with the U.S. Postal Service," Bezos said at Recode's 2016 Code Conference in Rancho Palos Verdes, reported Bloomberg.

Analysts say there is no reason to think Amazon's deal with Whole Foods will be limited to groceries. The company could one day use Whole Foods locations as a place for customers to drop-off e-commerce returns and make exchanges for items bought online. The stores could also be hubs to pick up non-grocery items, which would reduce delivery costs and provide an alternative for shoppers who don't want their packages left unattended on their porches.

"Ultimately, we see the deal allowing Amazon to take further share of its customer's wallet and see a large opportunity to leverage many of its technologies to grow and optimize the Whole Foods business. We are also highly confident that Amazon will leverage the new store footprint for much more than just selling groceries," said Daniel Salmon, an analyst for BMO Capital Markets.

The $13.7 billion deal for Whole Foods could pay off quickly, but it still runs counter to trends in the tech world, in which fixed assets like real estate and heavy equipment are shunned, said Amit Sharma, a former supply chain executive at Wal-Mart and now CEO of Narvar, a retail app.

"Look at companies in the sharing economy. You don't need to own assets long term," Sharma said.

But other experts see advantages to buying Whole Foods beyond just its gourmet and organic food, and access to the affluent customers who favor it.

Groceries can be a lure — one that consumers can't live without — which could result in more sales of Kindle e-books and other high-margin goods that could end up on Whole Foods' shelves.

"You don't shop for appliances multiple times a week. You don't shop for any durable goods multiple times a week. But you need to put fresh food on the table," said Lloyd Greif, a Los Angeles investment banker and president and CEO of Greif & Co. "That's what drives customer traffic. The more touch points you have with a consumer, the more you'll be able to sell them everything else. From Amazon's standpoint, they don't have to focus so much on making money on groceries if they make money everywhere else."