Many companies featured on Money advertise with us. Opinions are our own, but compensation and
in-depth research may determine where and how companies appear. Learn more about how we make money.

Money is not a client of any investment adviser featured on this page. The information provided on this page is for educational purposes only and is not intended as investment advice. Money does not offer advisory services.

A shopper inspects the fresh produce at a Walmart store in Secaucus, New Jersey
A shopper inspects the fresh produce at a Walmart store in Secaucus, New Jersey, November 11, 2015.
Lucas Jackson—Reuters

By most accounts, this was a good week for Walmart in its e-commerce battle against Amazon.com.

CEO Doug McMillon announced that Walmart expected a 40% jump in domestic online sales over the coming year. The low-price leader in food will also add 1,000 online grocery pickup locations and implement a new feature that reduces prices on goods for shoppers as they purchase more items. That's an offshoot of the “smart cart” pricing offered by Jet.com, the e-commerce startup that Wal-Mart bought last year for over $3 billion.

All of these initiatives signal that Walmart's e-commerce efforts are starting to pay off, which helped push the stock up 8% for the week.

But despite all the buzz Walmart has generated lately — including plans to offer in-home and in-fridge deliveries as well as 30-second online returns through its stores — the world's largest retailer still faces a stacked deck in its battle with Amazon.

“How do retailers compete online with a company that really doesn’t have to make money to keep shareholders happy?” asks Moody’s analyst Charlie O’Shea.

O’Shea is referring to the fact that Amazon's unique investor base — not its Prime members or customers — is what really sets the company apart.

Many investors trade on Amazon not based on its current profits or quarterly performance, but on long-term growth potential. That gives Amazon a real competitive advantage compared to a traditional company and stock like Walmart, where management has to worry about delivering on short-term results.

No where is this more evident than in groceries, now a focus of Amazon after it finalized its purchase of Whole Foods for $13.7 billion in August.

Walmart is still by far the leading grocer nationwide. Moody’s estimates that 27% of the $800 billion Americans spend annually in groceries go through Walmart. Even with the acquisition of Whole Foods (which saw $15.7 billion in sales last year), Amazon is still a much smaller player.

Normally, it's the dominant industry leader that dictates prices — putting pressure on smaller competitors with less financial flexibility. But it's different with Amazon because its shareholders give management so much leeway to be aggressive in the present to ensure growth down the road.

In the grocery space, the big fear among traditional players is that Amazon will continue to lower prices at Whole Foods to steal market share.

While this could make groceries even cheaper for you at home — last year consumers saw the first annual decline in grocery prices since 1967 — it represents a real threat to traditional grocery chains like Kroger or Albertson’s.

Again, Amazon is able to do this because there isn’t an overwhelming concern for short-term profit.

Walmart doesn’t have that flexibility. And all the goodwill the company received this week could be reversed with one bad quarter — not because of its customer base or e-commerce strategy, but due to shareholder demands for keeping costs down and profits up in the here and now.

That’s a tough battle to win.