Apple has reported better-than-expected earnings and offered a rosy forecast for the holiday shopping season, allaying investor concerns about production delays on the new iPhone X and demonstrating remarkable strength across its growing line of products and services.

The stellar earnings report came just as the iPhone X went on sale on Friday morning in Australia. Long lines were forming at Apple stores around the world, recalling the consumer frenzy that greeted early versions of the iPhone, but had faded with more recent launches.

With supplies potentially tight, some Australian purchasers were already planning to sell their phones for as much as A$3,000, nearly double the A$1,579 selling price.

Apple shares rose 4 per cent in after-hours trading to hit an all-time high, with analysts lavishing praise on Apple CEO Tim Cook and speculating on when Apple might become the first public company worth a trillion dollars.

The earnings demonstrate how Apple is able to drive growth across an ever-expanding product line that now includes five different iPhone models along with the iPad, the Mac, the Apple Watch and a suite of fast-growing services offerings.

“We had good success, I would say, through the different iPhones,” Mr Cook said on a call with analysts. “We tried hard to have an iPhone that is as affordable as possible for people that really want an iPhone, but may have a more limited budget.”

Apple unveils the iPhone X Show all 10 1 /10 Apple unveils the iPhone X Apple unveils the iPhone X Apple Senior Vice President of Worldwide Marketing, Phil Schiller, introduces the iPhone x during a launch event in Cupertino, California, U.S. September 12, 2017 REUTERS/Stephen Lam Apple unveils the iPhone X Apple Senior Vice President of Worldwide Marketing, Phil Schiller, introduces the iPhone X during a launch event in Cupertino, California, U.S. September 12, 2017 REUTERS/Stephen Lam Apple unveils the iPhone X Apple Senior Vice President of Worldwide Marketing, Phil Schiller, introduces the iPhone X during a launch event in Cupertino, California, U.S. September 12, 2017 Reuters Apple unveils the iPhone X Apple Senior Vice President of Worldwide Marketing, Phil Schiller, introduces the iPhone x during a launch event in Cupertino, California, U.S. September 12, 2017 REUTERS/Stephen Lam Apple unveils the iPhone X Apple Senior Vice President of Worldwide Marketing, Phil Schiller, introduces the iPhone x during a launch event in Cupertino, California, U.S. September 12, 2017 REUTERS/Stephen Lam Apple unveils the iPhone X Apple Senior Vice President of Worldwide Marketing, Phil Schiller, introduces the iPhone x during a launch event in Cupertino, California, U.S. September 12, 2017 REUTERS/Stephen Lam Apple unveils the iPhone X Apple Senior Vice President of Worldwide Marketing, Phil Schiller, shows Animoji during a launch event in Cupertino, California, U.S. September 12, 2017 REUTERS/Stephen Lam Apple unveils the iPhone X Apple Senior Vice President of Worldwide Marketing, Phil Schiller, speaks during a launch event in Cupertino, California, U.S. September 12, 2017 REUTERS/Stephen Lam Apple unveils the iPhone X Apple Senior Vice President of Worldwide Marketing, Phil Schiller, introduces the iPhone x during a launch event in Cupertino, California, U.S. September 12, 2017 REUTERS/Stephen Lam Apple unveils the iPhone X Tim Cook, CEO of Apple, speaks about the iPhone X during a launch event in Cupertino, California, U.S. September 12, 2017 REUTERS/Stephen Lam

Just a few weeks ago, Apple appeared to be facing a rare stumble with a delay in the iPhone X launch and rumours of production problems that could limit supply.

But Apple executives shrugged off the concerns as Chief Financial Officer Luca Maestri told Reuters the company was “quite happy” with how manufacturing of the iPhone X was progressing.

Analysts have been eager to see whether Apple can meet demand for the iPhone X during the crucial holiday quarter, with most saying it will likely take it until next year or early spring to do so.

“Where the demand curve and supply curve are going to intersect, we do not know. It does not have a predecessor product,” Mr Maestri told Reuters.

iPhone X: Review with David Phelan

Apple forecast fiscal first-quarter revenue of $84bn to $87bn, at the high end of analysts average expectations of $84.18bn, according to Thomson Reuters I/B/E/S.

“A trillion-dollar market cap may now be in Cook's sights in light of these results and guidance around iPhone X,” said Daniel Ives, an analyst at GBH Insights, referring to Apple's chief executive.

The Cupertino, California-based company's market capitalisation of about $868bn already makes it the world's most valuable publicly-traded company.

There are still questions around supplies of the new phone and longer-term demand.

Bob O'Donnell, head of Techanalysis Research, cautioned that if Apple is not able to fill demand for iPhone X over the holiday quarter, it would push buyers to wait until Apple's March quarter, by which time they may have spent their money elsewhere.

“What we don't know is, how long will this first group of (iPhone X buyers) last?” Mr O'Donnell said.

Apple said it sold 46.7m iPhones in the fourth quarter ended Sept. 30, above analysts' estimates of 46.4m, according to financial data and analytics firm FactSet. However, average selling prices of $618 fell short of forecasts of $638.

The company's net income rose to $10.71 billion, or $2.07 per share, in the quarter, from $9.01 billion, or $1.67 per share, a year earlier. That beat the average analyst estimate of $1.87 per share.

Apple forecast a gross margin of 38 per cent to 38.5 per cent, higher than many analysts expected because new products often have higher costs.

Mr Maestri attributed the margin strength to Apple's growing services business, which brought in $8.5bn in revenue compared to analyst estimates of $7.5bn. That included a favourable $640m adjustment, though Apple officials did not elaborate.

The $28.85bn revenue from iPhone sales accounted for nearly 55 per cent of total revenue, which rose 12.2 per cent to $52.58bn.

Analysts on average were expecting total revenue of $50.7bn, according to Thomson Reuters I/B/E/S.

Apple also said it returned to revenue growth in China, bringing in $9.8bn compared with $8 billion a year ago, driven by double-digit unit sale increases of the iPhone. Mr Maestri also told Reuters the company had doubled its revenue in India during the fiscal fourth quarter, though he did not give any details.