handshake

A URL is a promise. This is the round-trip bill.

From URL to first byte, drawn to scale.

Before a browser can render a page it has to find the server, open a connection, agree on encryption, ask for the document and wait. Those steps cost round trips, not megabytes — which is why a 200 KB page can feel slower than a 2 MB one, and why the first visit to a site feels different from the second.

This is a model, not a measurement. Nothing here opens a connection or reads your network. It counts protocol round trips and transfers at the bandwidth you choose, and it says where the arithmetic is approximate. Change anything below and the timeline is rebuilt in front of you.

Result

— to first paint
Round trips
—
On the wire
—
First byte
—

Watch the round trips accumulate.
Waterfall Each bar is one phase, on the same time axis as the diagram below.
Space–time diagram Down is a request, up is a response. Every V is one round trip.
For a ticket, a comment or a code review.

Four ways to load the same idea

Scaled against the slowest of the four, so the bars mean something next to each other. The warm revisit is not a faster network: it is the same network with the set-up already paid for.

What is actually being counted

Seven phases, in order. Each one is either latency (a round trip, paid in milliseconds regardless of size) or transfer (bytes, paid in bandwidth). Almost every "the site is slow" conversation is really a question about which of those two the page is spending its time on.

  1. DNS. Name to address. Three round trips cold, one with a warm resolver, none if the OS still has it.
  2. Transport. TCP's SYN, SYN-ACK, ACK: one round trip. QUIC does the same job with TLS inside it, so HTTP/3 pays once instead of twice.
  3. TLS. One round trip on 1.3, two on 1.2. This is the whole timing difference between the versions on a fresh connection.
  4. Request and first byte. Half a round trip out, the server's own think time, half a round trip back.
  5. Document. The HTML body at line rate, with a slow-start allowance on a new connection.
  6. Subresources. More requests. HTTP/1.1 queues them six connections at a time; HTTP/2 and HTTP/3 multiplex them over one connection, which is the difference between waves and a single crossing.
  7. Parse and paint. The device's turn. The roughest estimate here, and the only one that is not network at all.

The arithmetic is deliberately simple: ms = roundTrips × RTT + serverTime + bytes ÷ bandwidth. The interesting part is not the sum, it is the shape — and the shape is why the same page can be fast on a laptop in Johannesburg and slow on a phone in a lift.

What this is not

Why the round trips matter more than the megabytes

Latency is a floor, not a cost you can optimise away with a bigger pipe. On a 120 ms mobile link, a connection that needs DNS (3), TCP (1), TLS (1) and a request (1) has spent 720 ms before the first byte of HTML arrives — with an empty pipe the whole time. Doubling the bandwidth changes none of it. Removing a round trip changes all of it.

That is the argument for keep-alive, for HTTP/2 and HTTP/3, for CDNs and for edge caches: not "faster downloads", but fewer conversations. When someone says a site is slow on mobile but fine on the office network, this is usually the diagram they need to see.