The legality of end-to-end encryption varies depending on the country and its laws regarding encryption. In many jurisdictions, end-to-end encryption is legal and widely used. However, some governments have proposed or implemented regulations that aim to weaken encryption or mandate the inclusion of backdoors for law enforcement purposes.