Shares rose as much as 11 percent in extended trading. Their after-hours peak would beat the current all-time high reached in July and would equal gains of about 100 percent this year. (Click here to follow the stock.)

Amazon reported third-quarter earnings of 17 cents per share on $25.36 billion in revenue. Analysts expected Amazon to post a loss of 13 cents per share on $24.91 billion in revenue, according to a consensus estimate from Thomson Reuters.

Amazon shares spiked Thursday after the high-spending company posted its second-straight quarterly profit, boosted by strong North American sales and cloud computing growth.

Net sales rose 23 percent from the previous year. Amazon's earnings of 17 cents per share compared to a loss of 95 cents per share a year earlier. Sales in North America also rose 28 percent year over year to $15.01 billion, from $11.7 billion a year ago.



Read MoreJeff Bezos makes another $5B on Amazon's monster quarter



Wall Street watches the company's fast-growing Amazon Web Services segment closely. The business took in $2.09 billion in revenue in the quarter, a gain of about 78 percent from $1.17 billion in the previous year. It topped analysts' expectations of $1.99 billion, according to StreetAccount.

"Really, the story is AWS. Really, this stock broke out when they broke out these kinds of results," Stephanie Link, managing director and portfolio manager at TIAA-CREF, said Thursday.

Amazon's operating income was $406 million in the quarter, compared to an operating loss of $544 million in the previous year.

"They proved last quarter they can deliver on EPS, revenue and margins, and they did it again now," Guy Adami, director of advisor advocacy at Private Advisor Group, said Thursday.

The e-commerce giant also forecast a "record" holiday season, expecting net sales between $33.5 billion and $36.75 billion. The top end of that range exceeds Wall Street's estimates of about $35 billion.

Amazon also expects an operating income between $80 million and $1.28 billion. The company has already started preparing for increased demand, announcing this week it would hire 100,000 seasonal employees for the holiday period.

Even before Thursday, Amazon shares blew past broader markets this year, with gains of more than 80 percent.