Amazon earnings more than double, sending stock toward record highs

views Inc.’s massive growth just grew even more massive in the first quarter, as the e-commerce giant reported Thursday that profit more than doubled and sales continued to accelerate.

Amazon AMZN, +3.96%  reported net income of $1.6 billion, or $3.27 a share, up from $724 million, or $1.48 a share, a year ago. Revenue jumped 43% from last year, to $51 billion from $35.7 billion. The report blew away expectations: Analysts on average projected Amazon to report earnings of $1.24 a share on sales of $49.9 billion, according to FactSet.

After closing with a 4% gain at $1,517.96, shares jumped more than 7% in after-hours trading immediately following the report’s release, hitting prices that would top Amazon’s record intraday high if they were reached during regular trading. Amazon shares have already gained 29.4% so far this year, as the S&P 500 index SPX, +1.04%  has declined 1.3%.

Amazon’s revenue growth has been accelerating despite its size and maturity, with 2017 sales growing 30.8% after expanding 27.1% in 2016 and 20.3% in 2015. That growth has allowed Amazon to become hugely profitable, after the company’s early struggles with net losses caused criticism of Chief Executive Jeff Bezos’s habit of large spending totals on initiatives like fulfillment centers for delivery and data centers for Amazon Web Services.

Opinion: Ranking Amazon, Alphabet, Apple and Microsoft in the race to $1 trillion

The growth reported Thursday dwarfs even Amazon’s impressive growth in previous quarters, though. Amazon profit increased 221% year-over-year, the most the company has ever reported in a single period.

AWS, the company’s cloud-computing arm, was the biggest driver of that profit. Amazon said AWS had operating income of $1.4 billion, up from $890 million, as revenue topped $5 billion for the second consecutive quarter, at $5.44 billion. AWS revenue grew 48.6% from the year before, while operating income increased 57.3%.

“AWS had the unusual advantage of a seven-year head start before facing like-minded competition, and the team has never slowed down,” Bezos said in Thursday’s announcement, later adding: “That’s why you’re seeing this remarkable acceleration in AWS growth, now for two quarters in a row.”

See also: The typical Amazon worker made less than $30,000 in 2017

Amazon is more widely known for its lower-margin e-commerce business, though, which has continued to grow into a powerful force. That business provided the bulk of the revenue, though less profit than the much smaller AWS. While Amazon’s business in North America brought in $1.15 billion in operating income on $30.73 billion in sales, the company’s international sales were not profitable, with an operating loss of $622 million on sales of $14.88 billion.

Bezos revealed for the first time last week that Amazon Prime, a service that provides free two-day shipping on many orders along with access to Amazon’s streaming-video service and other perks, had surpassed 100 million subscribers. The announcement led some to wonder if Prime growth has peaked, but there was no sign of that in Thursday’s report. The company’s subscription services segment, which includes Prime as well as other subscriptions, such as an e-books offering and Amazon Music, grew 60% year-over-year to $3.1 billion in sales.

Read: Amazon has ‘iron grip’ on e-commerce, Prime membership disclosure shows

Amazon has also moved into brick-and-mortar retail, acquiring the grocer Whole Foods and recently striking a deal with Best Buy Co. Inc. BBY, +1.67%  . Amazon’s physical-store sales, which the company did not report before the Whole Foods acquisition, reported $4.26 billion in sales, down slightly from $4.52 billion in the holiday shopping quarter.

Amazon has continued to spend heavily and make no apologies for it. The amount Amazon has spent has even been a focus of the Securities and Exchange Commission, which has sought more disclosure from Amazon on exactly how much it is spending on segments like AWS and its Alexa digital assistant. Despite the big gains in profit over the past year, Amazon actually has less cash on hand than a year ago, reporting slightly under $25 billion in cash against almost $31 billion a year ago.