Why 2017 Was a Year to Remember for Wal-Mart Stores Inc.

Investors in Wal-Mart Stores (NYSE: WMT) must have been wondering what the world was coming to. In 2015, while the broader market ended the year just short of breakeven, the stock for the retailer was down a dismal 29%. For the fiscal year that ended January 31, 2016, revenue fell 0.7% year over year, while net income dropped 10% and same-store sales rose a pitiful 0.6%. This marked the first time the company had failed to increase its sales since the company went public in 1970.

Results for the following year were only slightly better, with revenue up 0.8% year over year, while net income fell 7% and comparable same-store sales rose 1.8%. Competition from e-commerce juggernaut Amazon.com (NASDAQ: AMZN) weighed heavily on the retailer, and prognostications concerning the death of the American retailer were rampant.

Last year was another story, though. Investments the company made in the online sales arena, as well as a variety of shipping and in-store pickup initiatives, began to bear fruit and brought investors back from the sidelines. 2017 will be remembered as the year that Wal-Mart put Amazon on notice that it had its own e-commerce and omni-channel chops -- and that it was a force to be reckoned with.

A year of transformation and rebirth

The seeds for Wal-Mart's remarkable about-face were actually planted in August 2015 with the purchase of online retailer Jet.com for $3.3 billion. This was the first of several such acquisitions the company made in an effort to position Wal-Mart to compete in the rapidly growing area of e-commerce. Other purchases included outdoor retailer Moosejaw, men's clothing company Bonobos, and women's fashion clothier Modcloth.

The most important acquisition was that of Jet.com founder Marc Lore, who Wal-Mart appointed its head of e-commerce. Lore brought a start-up mentality to the company's efforts to revamp its online strategy.

Several initiatives highlight Wal-Mart's ongoing transformation into an omni-channel powerhouse. Wal-Mart and subsidiary Jet.com began offering free two-day shipping on orders of $35 or more -- emphasizing that "it's all available to you without joining a membership club or paying extra fees for the privilege," in a not-so-thinly veiled shot at Amazon.com. The company also acquired delivery service Parcel, which arranged same-day shipping for meal kits and online retailers in New York. Parcel's automated delivery platform will provide Wal-Mart with the technological foundation to expand its own shipping efforts.

Wal-Mart piloted test projects that encouraged the stores' employees to drop packages to customers on the way home, and it brought in giant vending machines that allow customers to order online and pick up those items in the store for a discount.

Jet.com also introduced a new fun and edgy private-label brand called Uniquly J, targeting millennials with colorful packaging, irreverent copy, and bold designs to appeal to younger shoppers in a way that the company's legacy private-label brands -- Equate, Sam's Choice, and Great Value -- never did.

The proof is in the pudding

In its 2018 fiscal third quarter (which ended October 31, 2017), the company reported revenue that increased 4.2% year over year and comparable same-store-sales that jumped 2.7%. Excluding one-time items related to the hurricane and extinguishment of debt, profits exceeded those of the prior-year quarter. Even more importantly, the company's e-commerce sales jumped 50% over the prior-year quarter.

The company is increasingly focused on its online and omni-channel capabilities. In late 2017, Wal-Mart Stores announced that it would be dropping both the hyphen and the "Stores" from its name, in a nod to the company's ongoing move into e-commerce.

Wall Street is beginning to notice

Analysts at Citi Research issued a rare and laudable "mea culpa" regarding its previous call on Wal-Mart. In a note to clients, Kate McShane wrote (emphasis mine):

The most noticeable change for investors has been in the stock performance. After two disappointing years, Wal-Mart's stock was up an impressive 43% in 2017, more than double the broader market's 19% rise.

Look for the company to continue its winning ways as more of Wal-Mart's initiatives take hold and it pushes further into the realm of e-commerce. 2017 was a year to remember for Wal-Mart.

10 stocks we like better than Wal-Mart StoresWhen investing geniuses David and Tom Gardner have a stock tip, it can pay to listen. After all, the newsletter they have run for over a decade, Motley Fool Stock Advisor, has tripled the market.*

David and Tom just revealed what they believe are the 10 best stocks for investors to buy right now... and Wal-Mart Stores wasn't one of them! That's right -- they think these 10 stocks are even better buys.

Click here to learn about these picks!

*Stock Advisor returns as of January 2, 2018

John Mackey, CEO of Whole Foods Market, an Amazon subsidiary, is a member of The Motley Fool's board of directors. Danny Vena owns shares of Amazon. The Motley Fool owns shares of and recommends Amazon. The Motley Fool has a disclosure policy.