Tech giant Facebook has accused the Australian, United States and British governments of demanding a fundamental weakening of the company's products that would be a "gift" to the world's criminals, hackers and dictators and endanger innocent people.

Executives from Facebook – which operates WhatsApp, Instagram and Messenger – have declared they will not compromise the security of their messaging services for the sake of law enforcement, firing back at Western governments that recently demanded the company abandon plans to encrypt communications across its products.

Tech giant Facebook has taken on the Australian, United States and British governments. Credit:Bloomberg

In October, Home Affairs Minister Peter Dutton, US Attorney-General William Barr, acting US Secretary of Homeland Security Kevin McAleenan and British Home Secretary Priti Patel wrote to Facebook founder Mark Zuckerberg, warning the company's plans would hamper investigations if there was no avenue for law enforcement agencies to gain access to user data.

End-to-end encryption is the method of encoding communications so they are accessible only to the sender and recipient. In a letter responding to the officials, Facebook defended user privacy as the "core principle" of encryption and said no one else could intercept the messages, including the company itself.