Frontend Labs
⋯

Part 1 — What is a network, really?

Machine set up, route chosen — time to start. Before any protocol or packet, there's one question worth answering slowly: what problem is a network actually solving, and why did it end up built the way it is? Everything in the following twelve parts is an answer to some version of that question.

Chapter 1 — The problem networks solve

In one sentence

A network's job is to get a chunk of data from a program on one machine to a program on another machine, over links that are slow, unreliable, owned by strangers, and constantly changing.

The problem

Say you want to send a photo from your laptop to a friend's phone in another country. Sounds simple. Now list what could go wrong:

  • Your laptop and their phone have no wire between them. There are maybe fifteen machines in between, owned by six different companies.
  • Those machines are shared with millions of other people doing the same thing right now.
  • Any link along the way can drop your data silently — a cable is unplugged, a router is overloaded, a Wi-Fi signal is interfered with.
  • Data can arrive out of order, or twice, or corrupted.
  • The path can change mid-transfer because a router somewhere failed.
  • The machines run different operating systems made by different companies decades apart.
  • Nobody is in charge of the whole thing.

And yet it works, hundreds of billions of times a day. The rest of this guide is how.

The idea, in plain language

Break the giant problem into small problems and solve each one separately, with a separate agreement (a protocol) for each.

Small problem The question it answers Who solves it
Framing Where does one message stop and the next begin on this wire? Ethernet, Wi-Fi (Part 2)
Local addressing Which physical device on this cable? MAC addresses, ARP (Part 2)
Global addressing Which machine on the planet? IP addresses (Part 3)
Routing Which way do I send it? Routers, routing tables (Part 3)
Which program? Machine has 50 programs — which one gets this? Port numbers (Part 5)
Reliability Did it arrive, complete and in order? TCP (Part 5)
Speed and fairness How fast can I send without breaking things? TCP congestion control (Part 6)
Names I only know example.com, not a number DNS (Part 4)

"TCP/IP" is the name for this whole family of agreements. It's not one protocol; it's about a dozen working together, and this guide takes them one at a time.

Worked example: the same problem, in the physical world

Getting a parcel from your house to a friend abroad:

YOU                                                     YOUR FRIEND
 |                                                            ^
 | write a note                                               | reads note
 v                                                            |
 put it in an ENVELOPE with their NAME                  opens envelope
 |                                                            ^
 v                                                            |
 put envelope in a BOX with their FULL ADDRESS          opens box
 |                                                            ^
 v                                                            |
 hand box to the LOCAL COURIER                          local courier
 |                                                       delivers
 v                                                            ^
 local depot -> national hub -> plane -> foreign hub -> local depot

Notice three things that map exactly onto networking:

  1. Each layer only reads its own label. The plane's loading crew doesn't read the note. The courier doesn't care what's in the envelope.
  2. The "next hop" changes constantly; the final address doesn't. Every depot asks "who do I hand this to next?", but the address on the box never changes.
  3. You only had to know the local courier. You didn't need to know the flight number or the foreign postal system.

That is the whole design of the internet. Chapter 2 makes it precise.

Common confusions

  • "Is the internet the same as the web?" No. The internet is the network (this guide). The web is one application that runs on it (HTTP, Part 7). Email, video calls, and games are other applications on the same internet.
  • "Who owns the internet?" Nobody. It's tens of thousands of independent networks that agree to interconnect using these protocols. That's why the protocols matter so much — they're the only thing holding it together.

Check yourself

  1. Name three things that can go wrong when data crosses a network.
  2. Why split the problem into separate protocols instead of one big one?
  3. What's the difference between the internet and the web?

(Answers: Appendix F.)

Further reading

  • Video (~9 min): "How does the internet work?" — Code.org's series with Vint Cerf (who co-invented TCP/IP). Start here; it's genuinely excellent.
  • Article: "How Does the Internet Work?" — Cloudflare Learning Center. Short, clear, no jargon.
  • Book (very readable): Tubes: A Journey to the Center of the Internet — Andrew Blum. The physical internet: cables, buildings, oceans. Non-technical and fascinating.
  • Video (~13 min): "The Internet: Packets, Routing & Reliability" — Code.org.

Generated from real-life-guide-v1.md · 8 Oct 2026 16:36