Wal-Mart Stores has forecast that its US online sales would soar about 40% in the fiscal year ending January 2019, sending its stock up 4.7% to the highest in more than two years.
The company also forecast overall net sales to rise by at least 3% in the same period and said it would buy back $20 billion of its shares over the next two years.
The retailing giant reiterated its focus on its e-commerce business at its annual investor meeting in Arkansas.
It has started offering free two-day shipping and plans to roughly double the locations for shipping online grocery orders and slash the number of physical stores.
Wal-Mart is locked in a battle for market share with ecommerce group Amazon.com.
It has been doubling down on its online business and leveraging its 4,700-plus stores trying to create a more hassle-free experience for online shoppers.
"We are going to lean into places like technology, e-commerce, international stores ... we feel like we are going in the right direction with that," Wal-Mart's chief financial officer Brett Biggs said.
The company did not break out US e-commerce sales last year, but reported growth of about 62% for the first half of this year.
With a steady rise in people buying online, Wal-Mart's e-commerce sales growth has been outstripping brick-and-mortar.
Wal-Mart plans to open fewer than 15 "supercentres" and less than 10 "neighbourhood markets" in the US in the fiscal year ending January 2019. That is half the stores it intends to open in fiscal 2018.
Last year, Wal-Mart opened 230 supercentres and neighbourhood markets.
In August, the company warned that current-quarter profit could miss Wall Street estimates as margins are being hurt by price-cutting and heavy spending on e-commerce.
The company said its total revenue increased 2.1% to $123.4 billion in the latest quarter. Wal-Mart did not break out total online sales.
Like other retailers, Wal-Mart has been investing aggressively. The company said today it expects capital expenditures to be about $11 billion for fiscal years 2018 and 2019.
It started offering free two-day shipping and discounts for picking up online purchases at stores, and has acquired several start-ups, including Jet.com for $3.3 billion last year.
Grocery competition has increased since Amazon bought Whole Foods and started to cut prices at the upmarket grocer in August.
Wal-Mart forecast fiscal 2019 profit would increase about 5% over the expected adjusted earnings of $4.30 to $4.40 per share for the year ending January 2018.
The new buyback replaces the existing $20 billion programme announced in October 2015. In the seven quarters since, Wal-Mart had bought back $15.10 billion worth of shares.
It was not immediately clear how much of the remaining $4.9 billion under the old plan it had used in the current quarter.