It was the belated birthday present no one saw coming: One week after turning 20, Amazon was handed the scepter and crown of US retail after the online behemoth posted a surprise second-quarter profit.

The unexpected earnings prompted almost giddy reactions from investors and market analysts, who helped push the company's shares up 17 percent in after-hours trading Thursday to $566 (515.6 euros). Or as Amazon investor and analyst with the Motley Fool website, Jason Moser, pithily put it:

Changing of the guard

Thundering cloud-computing sales coupled with strong revenue growth at home and abroad triggered a strong aftermarket surge, putting the value of Jeff Bezos' e-commerce empire at about $265 billion and ending the long-time retail reign of Walmart, whose market cap was $233.5 at close.

While Walmart managed to hang on to the retail throne in terms of total revenue, some experts speculate it is only a matter of time before that too will be wrested from the Arkansas-based company as digital stores increasingly win over consumers.

“Walmart has been the de facto retail king for the last 20 years,” the New York Times quoted Jason Moser as saying. “They were very good at bringing the consumer to the store. But technology changes so fast. What Amazon is doing is building a company focused on bringing the store to the consumer.”

Since launching as an online bookseller in 1994, Amazon has grown into one of the leading virtual markets worldwide, offering anything from apparel to home entertainment systems and boats.

The pull of Prime

In the April-June quarter, Amazon posted net come of $92 million, or 19 cents per share, up from a loss of $126 million a year earlier. On average, Wall Street analysts had predicted a loss of 15 cents per share. Revenue in the period jumped 20 percent to $23.2 billion in the period, the Seattle-based online retailer said on Thursday.

Earnings from its Web Services, which offer businesses a wide range of products via the "cloud," climbed 81 percent to $1.82 billion.

The company's $99-a-year Prime loyalty program also helped fuel growth, as the VIP service attracted new subscribers at rates "higher than we've ever seen," Amazon's new CFO Brian Olsavsky said in a call with analysts.

While the company declined to disclose exact membership figures, it is estimated that some 40 million have signed up for the program so far.

More to come?

Amazon said it expected revenue for the current quarter as high as $25.5 billion. So far this year, Amazon shares have soared 55 percent.

Olsavsky said the company would continue to look for ways to keep costs in check while at the same time investing in "things that we think are big and important."

"We've been in competition with some of the biggest names in retail," he added, "so we're used to competition but we're focused on the customer."

pad/hg (AP, dpa, Reuters)