What is Onion Routing?
A technique for anonymous communication over a computer network where messages are encapsulated in layers of encryption, analogous to layers of an onion. Each relay decrypts one layer to reveal the next destination, but no single relay knows both the origin and final destination.
Also known as: Onion Network
Onion routing wraps your data in multiple layers of encryption, like an onion. As your data passes through each relay, one layer is "peeled off," revealing only the next step—never the complete journey.
How It Works
- Client selects path: Your device chooses multiple relays (typically 3)
- Layered encryption: Message is encrypted in layers, one for each relay
- Entry node: First relay decrypts outer layer, sees only middle relay
- Middle relay: Decrypts its layer, sees only exit node
- Exit node: Final decryption, sends to destination
- No single point knows everything: Entry knows you, exit knows destination, middle knows neither
The Key Insight
Each relay only knows:
- Where the message came from (previous hop)
- Where it's going next (next hop)
No relay can determine both:
- The original sender
- The final destination
Visual Analogy
[Your Message]
↓ Encrypt for Exit
[Layer 3: Exit instructions]
↓ Encrypt for Middle
[Layer 2: Middle instructions + encrypted Layer 3]
↓ Encrypt for Entry
[Layer 1: Entry instructions + encrypted Layer 2]
Applications
- Tor Browser: Most common onion routing implementation
- I2P: Alternative anonymous network
- Onion services (.onion sites): End-to-end encrypted hidden services
Limitations
- Slower speeds: Multiple hops add latency
- Exit node visibility: Unencrypted traffic visible to exit
- Traffic analysis: Timing correlation attacks possible
- Trust assumptions: Relies on diverse, honest relay operators
Related Terms
Anonymity
The state of being unidentifiable or untraceable. In privacy contexts, anonymity means your actions cannot be linked back to your real identity—no one can connect your online activity to who you are.
Encryption
The process of converting information into a code to prevent unauthorized access. Encryption transforms readable data (plaintext) into an unreadable format (ciphertext) using a cryptographic algorithm and key. Only those with the correct key can decrypt and read the original data.
Tor Network
A free, open-source software and network that enables anonymous communication by directing Internet traffic through a worldwide volunteer overlay network of thousands of relays. Tor conceals users' locations and usage from surveillance and traffic analysis.
Have more questions?
Use our guided flow to get the right next privacy step for Onion Routing.
Open Guided Flow