HTTP: The Language of the Web
Your device found the server. Good. But finding someone and understanding them are two different things. To trade web pages, both sides need a shared set of phrases — a polite little script they both already know. That script is called HTTP: HyperText Transfer Protocol.
Think of it as ordering at a counter. You walk up and ask for one thing. The person behind the counter goes and gets it, hands it over, and clips on a small note that says how it went. You ask, they answer. That back-and-forth is the whole heart of the web.
The request: you ask for something
When you click a link or type an address, your browser sends a request to the server. A request is short and specific. It names what you want and what you'd like done with it.
The "what you'd like done" part is the method — a single verb. The everyday one is GET, which simply means "please hand me this page." Another common one is POST, which means "here's some information from me" — like the words you type into a search box or a sign-up form.
The request also carries a little stack of headers: small labels with extra details. One might say which language you'd prefer. Another names your browser. They're like the side notes on an order slip — "no ice," "for here, not to go." The server reads them to serve you better.
The response: they answer
The server takes your request, finds what you asked for, and sends back a response. The response has two parts that matter to us.
First, the body — the actual goods. That's the page itself: the text, and the instructions for the pictures and styling your browser then assembles into what you see.
Second, the status code — that little note clipped to your order saying how it went. It's a three-digit number, and the first digit tells the story:
- 200 means "OK, here you go." This is the quiet success you never notice.
- 301 or 302 means "moved — look over there instead." The browser quietly follows.
- 404 means "not found." You asked for a page the server doesn't have. The famous one.
- 500 means "something broke on my end." The counter, not your order, dropped the ball.
A handy way to remember the families: 400s are your side of the counter (you asked for something wrong or missing), and 500s are their side (the kitchen had a problem).
One more thing worth knowing: each request-and-response is its own small errand. The server doesn't remember your last ask once it's done. That forgetfulness is actually a feature — it keeps the web simple and lets one server help millions of people without keeping a running tab on each one. 🔦
Your turn
Open any website. If your browser has a menu item like "Developer Tools," find the Network tab and reload the page. You'll see a list of requests flying out, each one with a status number beside it. Watch how many separate little errands one page actually takes — and notice how almost all of them say 200.
Next we'll lock that conversation so no one can read it on the way: HTTPS.
Stuck or curious?
Ask Pip about this lesson — tap the porthole bottom-right.