Facebook last night beat Wall Street expectations for both quarterly revenue and profit but warned that growth later this year could "significantly" decline as new Apple privacy policies will make it more difficult to target ads.
A surge in digital ad spending during the pandemic when consumers shopped online, along with higher ad prices, helped Facebook revenue surge 48%.
Looking ahead, the world's largest social network said it will focus on building e-commerce features to expand beyond its ad business.
Shares of Facebook rose 6.5% to $326 in extended trading.
"We have a long way to go to build out a full-featured commerce platform, but I am very committed to getting there," Facebook chief executive Mark Zuckerberg told analysts on a conference call to discuss earnings.
Total revenue, which primarily consists of ad sales, hit $26.17 billion in the first quarter ended March 31, beating analysts' average estimate of $23.67 billion, according to IBES data from Refinitiv.
The digital advertising industry has boomed during the pandemic, benefiting Facebook and others including Google, whose parent company Alphabet reported record quarterly profit on Tuesday.
Zuckerberg said the company plans to focus on three key areas - building augmented and virtual reality, e-commerce features and helping content creators earn money on Facebook's platforms.
Monthly active users on Facebook rose 10% to 2.85 billion.
Net income for the first quarter came in at $9.5 billion, or $3.30 per share, compared with $4.9 billion, or $1.71 per share, a year earlier. Analysts had expected a profit of $2.37 per share.
Facebook said its total expenses for the year would be in the range of $70 billion to $73 billion, as it invests in consumer hardware products like Oculus virtual reality headsets and infrastructure.
Facebook said it expects the iPhone privacy change to impact the second quarter, but third- and fourth-quarter revenue growth could slow sequentially.
It has blasted Apple over its requirement that iPhone app developers begin asking users' permission to collect certain data for ads. Facebook says the change would harm its business and hurt small companies that rely on personalised advertising.
Its push to build shopping and e-commerce features within Facebook and Instagram are expected to bring additional revenue to the company and make its ad inventory more valuable.
The company recently teased a slew of new features, including an affiliate programme to let content creators earn a cut of sales generated from recommending products on Instagram.
Earlier this month, Facebook announced it was building a bevy of audio products including live audio rooms to rival the popular app Clubhouse plus in-app music and podcast players.
The company remains under scrutiny over its power as it faces major competition lawsuits from a large group of US states and the Federal Trade Commission, and is under regular fire from lawmakers and rights groups for its content moderation policies, algorithmic systems and handling of users' data.