π A packet's-eye view of the internet
What happens when you type google.com?
Follow one tiny envelope of data β called a packet β on its real, step-by-step trip from your keyboard to Google and back. Small steps. Big colors. No magic, just mail. π¬
1
Check memory first
Have I been here before?
- You hit Enter after typing google.com.
- Your computer checks its own memory before asking anyone else β just like checking your backpack before asking a teacher.
- It checks 3 spots, in order: browser cache β OS cache β hosts file.
- Found it? Skip straight ahead. Not found? Time to ask the internet's phonebook.
2
DNS β the internet's phonebook
Turning a name into an address
- Computers don't understand "google.com" β they need a number, called an IP address.
- Your computer asks a DNS resolver (usually run by your Wi-Fi/internet company).
- The resolver may not know either, so it asks around: a root server β a .com server β Google's own server.
- Answer comes back: google.com = 142.250.192.14. Saved for next time!
3
ARP β meet your neighbor
Finding the router's "fingerprint"
- An IP address gets you close, but on your own home network your PC needs the router's exact hardware ID: its MAC address.
- Your PC shouts to everyone on the network: "Who has 192.168.1.1?"
- The router shouts back: "That's me! Here's my MAC address."
- Your PC saves this in its ARP cache so it doesn't have to shout again for a while.
4
Building the packet
Envelopes inside envelopes
- HTTP β the actual question: "please send the homepage."
- TCP β wraps it with tracking numbers so nothing gets lost.
- IP β adds the "from" and "to" address for the long trip.
- Ethernet β the outer envelope for just the first local hop.
5
Say hello politely
The TCP + TLS handshake
- Before sending the real question, both sides check they can hear each other β a 3-way handshake.
- Since Google uses HTTPS, there's one more step: a TLS handshake where both sides agree on a secret code, like a made-up whisper language.
6
The long trip
Hopping across the whole internet
- The packet leaves your PC and passes through your router, then your ISP, then many internet routers β like mail sorting centers.
- Each router reads the "to" address and passes it a little closer to Google β often crossing cities or even oceans.
- This usually takes just milliseconds!
7
Google replies
The webpage comes back
- Google's server unwraps your packet, reads "please send the homepage," and builds its own packets addressed back to you.
- A whole webpage is big, so it comes as many packets, each numbered.
- Your computer collects them all and puts them back in order β like numbered puzzle pieces.
8
Ta-da!
Your browser draws the page
- All the packets are reassembled into the full webpage code (HTML, CSS, images).
- Your browser reads that code and paints the page on your screen.
- Total time for all 8 stops? Usually under a second. π
The whole trip, at a glance
1Check caches
2DNS lookup
3ARP for router
4Build packet
5TCP/TLS handshake
6Hop across internet
7Google replies
8Browser renders
Ethernet
Gets the packet across just your local network β first hop only.
IP Address
A computer's mailing address, like 142.250.192.14.
TCP
Numbers the pieces so none get lost or arrive out of order.
HTTP
The actual question: "please send me this webpage."
DNS
The phonebook that turns names into IP addresses.
