This article is free to read. Creating a lesson uses your daily or stored credits; review the language and settings before starting.
How does end-to-end encryption work?
Quick answer
End-to-end encryption locks a message on the sender's device using the recipient's public key. The encrypted data travels through servers that cannot read it, and only the recipient's private key can unlock it. This ensures that no one in the middle—not even the service provider—can access the content.
End-to-end encryption scrambles messages on the sender's device so only the recipient's device can decrypt them. The service provider relays the encrypted data but never holds the keys, so it cannot read the content.
Step by step
- Each user's device creates a mathematically linked pair of keys: a public key to share and a private key kept secret.
- The sender's device encrypts the message with the recipient's public key, turning it into unreadable ciphertext.
- The ciphertext is sent through the service's servers, which relay it without being able to decrypt it.
- The recipient's device receives the ciphertext and decrypts it using its private key, revealing the original message.
Key things to understand
- Each user's device generates a public key, which can be shared, and a private key, which never leaves the device.
- When a message is sent, the sender's device encrypts it using the recipient's public key.
- The encrypted message travels through the service's servers, which cannot decrypt it because they lack the private key.
- Only the recipient's device can decrypt the message using its private key, which is mathematically linked to the public key.
- Even if the service is hacked or compelled to hand over data, the encrypted messages remain unreadable without the private keys.
Labelled diagram
- Key generation
Each device creates a public key to share and a private key kept secret.
- Encryption
Sender's device uses recipient's public key to lock the message.
- Transmission
Encrypted message passes through servers that cannot read it.
- Decryption
Recipient's device uses its private key to unlock the message.
Real-world examples
- When you send a WhatsApp message, it is encrypted on your phone and only decrypted on the recipient's phone.
- Signal uses end-to-end encryption for all messages and calls, so even Signal's servers cannot listen in.
- Apple's iMessage encrypts messages end-to-end between Apple devices, but backups to iCloud may not be encrypted.
- Zoom offers an optional end-to-end encrypted meeting mode, in which only participants' devices hold the keys.
Common mistake
✗ Myth: End-to-end encryption means the service provider can still read your messages if required.
✓ Fact: In true end-to-end encryption, the service provider never has access to the decryption keys, so it cannot read messages even if compelled. Only the communicating devices hold the private keys.
People also ask
How does end-to-end encryption work?
What does end-to-end encryption mean?
Is end-to-end encryption safe?
What is the difference between end-to-end encryption and regular encryption?
Can the police or government read end-to-end encrypted messages?
Is end-to-end encryption unbreakable?
Which apps use end-to-end encryption?
Part of the guide: How the Internet Works →

