(CNN) - Facebook is bracing for a massive fine from federal regulators after a year of data privacy scandals.
Facebook said Wednesday that it expects an ongoing investigation from the Federal Trade Commission could result in fines ranging from $3 billion to $5 billion.
The company set aside $3 billion in legal expenses related to the investigation, which cut into its profit for the first three months of 2019. Facebook's profit for the quarter was $2.4 billion, a decrease of 51% from the same period a year ago.
"This matter is not resolved so the actual amount of payment remains uncertain," David Wehner, Facebook's CFO, said on a conference call with analysts on Wednesday after the earnings report. "However we are estimating this range of loss to be $3 to $5 billion."
An FTC spokesperson declined to comment.
Facebook's confirmation of a massive fine, which had been rumored in recent months, didn't appear to unnerve investors, though. Shares of Facebook rose as much as 10% in after hours trading Wednesday following the news.
The fine would mark the first financial penalty for Facebook in the US since the Cambridge Analytica scandal came to light last March. Since then, Facebook has also come under public scrutiny for offering more of its users' data to companies than it had previously admitted.
Both incidents raised the prospect that Facebook had violated a 2011 consent agreement with the FTC, which required the social network to have a "comprehensive privacy program" and to get the "express consent" of users before sharing their data.
Previous FTC fines against technology firms had minimal teeth. In 2012, the FTC fined Google $22.5 million for violating an earlier privacy agreement with the agency. That same year, Google topped $50 billion in annual revenue for the first time.
But former FTC officials previously told CNN Business the agency may feel more pressure to make a statement with its fine against Facebook in light of all the public attention the company's data privacy scandals have received.
Even without the fine, analysts had expected the company to post a rare profit decline, as Facebook had indicated it would invest heavily in infrastructure and efforts to protect the platform from abuse.
The company previously said it expects its total expenses to increase by 40% to 50% in 2019 compared to the year prior, as it puts more money in data centers, augmented and virtual reality technology, and in safety and security.
At a conference in February, Wehner called the safety and security efforts "a big multi-billion dollar investment," which is "important for the long-term sustainability of the business." But on the call Wednesday, Wehner signaled expenses this year may be lighter than expected, not counting the money set aside for the FTC fine.
Last month, CEO Mark Zuckerberg said the company would emphasize private, encrypted and ephemeral conversations across its products in an attempt to reposition Facebook as a "privacy-focused" platform.
"People want to use both private and public platforms," Zuckerberg said on a conference call Wednesday. "Delivering this is both in the interests of our community and our business."
That said, Zuckerberg did admit some aspects of the shift to more privacy-focused features have the potential to hurt the business. "Reducing the permanence of data may have some impact," he said.
For all its scandals, Facebook's ad sales business continues to chugg along. Facebook's revenue for the quarter topped $15 billion, a 26% increase from a year earlier.
"Advertisers continue to be stuck on Facebook, despite its many challenges," said Debra Aho Williamson, principal analyst at eMarketer. "What they care most about is its vast user base and its targeting capabilities, and both are continuing to provide strong performance for them."
But there may be challenges ahead for its advertising platform. Wehner said Facebook expects "ad targeting headwinds will be more pronounced" in the second half of the year, in part because of product tweaks and user behavior changes in the wake of sweeping data protection regulation in Europe.
CNN's Donna Borak contributed to this report.
The-CNN-Wire ™ & © 2019 Cable News Network, Inc., a Time Warner Company. All rights reserved.