The nature of our digital communications today is such that you rarely communicate directly with your peers. It may seem that you and your friends are exchanging messages privately when, in reality, they're being recorded and stored in a central server.
You might not want your messages read by the server that's responsible for passing them between you and the receiver. In that case, end-to-end encryption (or more simply, E2EE) may be the solution for you.
End-to-end encryption is a method for encrypting communications between receiver and sender such that they’re the only parties that can decrypt the data. Its origins could be traced back to the 1990s, when Phil Zimmerman released Pretty Good Privacy (better known as PGP).
How do unencrypted messages work?
Let's talk about how a regular smartphone messaging platform might operate. You install the application and create an account, which allows you to communicate with others that have done the same. You write a message and enter your friend's username, then post it to a central server. The server sees that you've addressed the message to your friend, so it passes it along to the destination.
Users A and B communicating. They must pass data through the server (S) to reach each other.
You might know this as a client-server model. The client (your phone) isn't doing much – instead, the server takes care of all the heavy lifting. But that also means that the service provider acts as a middleman between you and the receiver.
Most of the time, the data between A <> S and S <> B in the diagram is encrypted. An example of this is Transport Layer Security (TLS), which is used extensively to secure connections between clients and servers.