Days after reports that a data analysis firm used by the Trump presidential campaign surreptitiously acquired and used Facebook data on 50 million people, Facebook CEO Mark Zuckerberg acknowledged for the first time Wednesday that his company was partially to blame. He vowed to take action and prevent such a data loss again.

"We have a responsibility to protect your data, and if we can't then we don't deserve to serve you," Zuckerberg wrote in a Facebook post. "I've been working to understand exactly what happened and how to make sure this doesn't happen again. The good news is that the most important actions to prevent this from happening again today we have already taken years ago. But we also made mistakes, there's more to do, and we need to step up and do it."

Zuckerberg laid out three steps that the company will take to prevent companies like Cambridge Analytica, the data firm used by the Trump campaign, from acquiring personal data. Facebook will begin an investigation into all apps that had access to user data before 2014, when the company changed what connected apps could access.

Facebook will also implement new restrictions on the data that apps are allowed to access, limiting them to use of a person's name, profile photo and email address.

Byers Market Newsletter Get breaking news and insider analysis on the rapidly changing world of media and technology right to your inbox. This site is protected by recaptcha

Lastly, Facebook will introduce a new tool to make it easier for users to see which apps have access to their data and to revoke access to any apps they no longer wish to be connected to.

Sheryl Sandberg, Facebook's chief operating officer, also posted to the social network to acknowledge the company's shortcomings.

"As [Mark Zuckerberg] said, we know that this was a major violation of peoples' trust, and I deeply regret that we didn't do enough to deal with it," she wrote.

Zuckerberg stopped short of directly addressing criticism that the company had erred in not notifying users or the public about the data usage, which it learned about in 2015. Facebook is currently under investigation by numerous state attorneys general and has received an inquiry from the Federal Trade Commission related to Cambridge Analytica's use of its data. Sen. Mark Warner, D-Va., also called for Zuckerberg to testify before Congress.

"This was a breach of trust between Kogan, Cambridge Analytica and Facebook," Zuckerberg wrote, referring to Cambridge University researcher Aleksandr Kogan. "But it was also a breach of trust between Facebook and the people who share their data with us and expect us to protect it. We need to fix that."

Zuckerberg's post had been strongly anticipated, as senior leadership at Facebook had been silent in the aftermath of the data breach news. The Cambridge Analytica incident brought new attention to how Facebook had previously allowed connected apps to take data from users that opted in, as well as data from the friends of those users.

Facebook has been under particular pressure to explain why the company did not notify users or the public that its data been used in a way that violated its terms of service. Facebook said on Friday that the company learned of the violation in 2015.

The lack of any public statement or appearance by Zuckerberg or Sandberg had led to growing questions about the company's response to the crisis. The hashtag "#WheresZuck" began to circulate on Twitter.

Facebook has faced privacy issues before but never with the kind of widespread attention and intensity of the Cambridge Analytica revelations. Numerous politicians have expressed concern, with Sen. Mark Warner, D-Va., calling for Zuckerberg to testify before Congress. Several state attorneys general are launching investigations, and the Federal Trade Commission is reportedly looking into the matter as well.

Facebook stock has dropped sharply in the past two days, wiping out almost $50 billion in value. The stock decline has reduce Zuckerberg's net worth by around $9 billion.