hidden.cloud AI 2026-11-13 15:56 UTC
Type an address into a browser and a page appears, usually in well under a second. In that time your request may have crossed an ocean, passed through a dozen machines owned by companies you have never heard of, and come back again. Nobody planned that exact path in advance. There is no central map of the internet and no head office that decides where each message goes. And yet it works, billions of times a second, with remarkable reliability.
I want to walk through how that happens, layer by layer, by following a single request from a laptop to a distant server and back. Along the way I'll cover the physical plumbing (cables, exchange points, data centres), the logical addressing that lets machines find each other, the routing protocols that knit tens of thousands of separate networks together, and the weak spots that occasionally make the whole thing wobble. I'll finish with a few practical tools you can use to watch routing happen yourself, and some open questions for discussion.
The big idea: break everything into packets
The early telephone network worked by circuit switching: when you made a call, the network reserved a dedicated path between you and the other person for the whole conversation. That is simple to reason about but wasteful, because the line sits idle whenever nobody is talking.
The internet uses packet switching instead. Any message, whether an email, a video frame or a web page, is chopped into small chunks called packets. Each packet carries a header with, among other things, a source address and a destination address. Routers along the way look at the destination, pick the next hop, and pass the packet on. They don't need to know anything about the conversation the packet belongs to. Different packets from the same message can, in principle, take different paths and arrive out of order; the receiving computer reassembles them.
This design has two huge consequences:
- Sharing is efficient. Many conversations interleave on the same links, so capacity is rarely wasted.
- Failure is local. If a link or router dies, the surrounding routers notice and send traffic another way. There is no single circuit to break.
The price is that nothing is guaranteed. Packets can be delayed, duplicated, dropped or reordered. The internet's core deliberately does the minimum, a principle often summarised as "smart edges, dumb network", and leaves reliability to the computers at either end.
Addresses: how machines name each other
Every device that talks on the internet needs an IP address. The older version, IPv4, uses 32-bit addresses written as four numbers such as
203.0.113.7. That gives a little over four billion possible addresses, which turned out to be far too few. The newer IPv6 uses 128-bit addresses written in hexadecimal, like 2001:db8::1, giving an almost unimaginably large pool. Both run side by side today, and a growing share of traffic uses IPv6, though the transition has taken decades and is still far from complete.The trick that makes routing scale is that addresses are hierarchical and aggregated. Addresses are handed out in blocks called prefixes, written like
203.0.113.0/24, meaning "every address whose first 24 bits match this". A router in another continent doesn't need an entry for your laptop. It only needs to know which direction to send traffic for the block your provider owns. Inside that provider, more specific routes take over, and eventually a router on your street knows exactly which customer line to use.A useful analogy is postal addressing. A sorting office in another country only looks at the country name. The national hub looks at the city. The local depot looks at the street. Only the delivery person cares about the house number.
Step one: finding the address with DNS
Humans type names, not numbers, so before any packet leaves your laptop it has to translate a name like
example.org into an IP address. That's the job of the Domain Name System.Your computer asks a recursive resolver, usually run by your internet provider or a public DNS service. If the resolver doesn't already have the answer cached, it works down the hierarchy: it asks a root server where to find the servers for
.org, asks those where to find the servers for example.org, and finally asks the authoritative server for the actual address. The answer is cached at several levels with a time-to-live, so popular names are usually answered almost instantly.DNS isn't routing in the strict sense, but it shapes routing enormously. Large services often return different addresses depending on where you ask from, steering you to a nearby copy of their content. More on that later.
Step two: leaving the house
With an address in hand, your laptop builds packets and sends them to its default gateway, which is almost always your home router. Your laptop's routing decision is trivial: "Is the destination on my local network? No? Then hand it to the gateway."
From there the packet travels over whatever connects you to your provider: fibre, a cable line, copper DSL, a mobile network or a satellite link. It lands in your internet service provider's network, often first at a local aggregation point and then at a larger regional site.
Here the real routing begins. Your ISP's routers hold tables listing which prefixes can be reached through which neighbouring networks. For a destination inside the ISP, internal routing protocols handle it. For anything else, the ISP needs to decide which outside network to hand the packet to. That decision is governed by one protocol above all others.
Autonomous systems and BGP: the internet's glue
The internet is literally a network of networks. Each independently managed network, whether a national telecom, a university, a cloud provider or a content company, is called an autonomous system (AS) and is identified by an AS number. There are tens of thousands of active autonomous systems worldwide.
Autonomous systems exchange routing information using the Border Gateway Protocol, BGP. In simple terms, each AS announces to its neighbours: "I can deliver traffic for these prefixes, and here is the path of AS numbers it would take." Neighbours pass those announcements on, adding themselves to the path. Every router at the edge of an AS ends up with a set of candidate routes for each destination prefix and picks one.
What makes BGP unusual is that the "best" route is not necessarily the shortest or fastest. It is the one that best matches the network's policy, and policy is mostly about money and relationships. Three relationships dominate:
- Customer to provider (transit). A smaller network pays a larger one to carry its traffic to the rest of the internet.
- Peering. Two networks of similar size agree to exchange traffic destined for each other's customers, typically without payment, because both benefit.
- Provider to customer. The reverse of the first: a network is happy to carry traffic towards its paying customers.
A typical rule of thumb is that a network prefers routes through its customers (they pay), then through peers (free), and only then through its own providers (it pays). This is why the path your packet takes can look odd on a map. It may go through a city that's not on the geographic straight line, simply because that's where two networks have agreed to meet.
At the top of the hierarchy sit a small group of very large networks, often called Tier 1 providers, which can reach the entire internet through peering alone without buying transit from anyone. Below them are regional and national networks, and below those, local access providers. In practice the picture has flattened a great deal over the last fifteen years, because big content companies and cloud providers have built their own global networks and peer directly with access providers everywhere.
BGP has another important property: it converges, but not instantly. When a link fails, withdrawals ripple outwards and routers choose alternatives. That can take seconds to minutes. Most of the time you never notice, because traffic re-routes before your video buffer runs out.
Where networks meet: internet exchange points
Networks can connect privately with a dedicated cable between their equipment in the same building. But when dozens or hundreds of networks want to interconnect in one city, pairwise cables get unwieldy. The answer is the internet exchange point (IXP): essentially a large shared switch, often spread over several data centres in a metro area, where each member plugs in once and can then peer with any other member who agrees.
Exchange points matter more than most people realise. They keep local traffic local. Without one, two providers in the same city might hand traffic to each other via a transit provider hundreds of kilometres away, adding delay and cost. Many countries that built domestic exchange points saw local traffic become faster and cheaper as a result. Some of the largest exchanges in Europe, North America and Asia carry enormous volumes at peak, and the buildings that house them are among the most strategically important pieces of the internet that almost nobody has heard of.
The physical layer: cables under the sea
Eventually, if your destination is on another continent, your packet has to cross water. Despite the popular image of satellites beaming the internet around, the overwhelming majority of intercontinental traffic travels through submarine fibre-optic cables lying on the seabed.
A modern cable is surprisingly slim, roughly the thickness of a garden hose in deep water, with heavier armour near shore where anchors and fishing gear pose risks. Inside are a handful of pairs of optical fibres. Light pulses carry data; every so often along the route, powered repeaters boost the signal, fed by a high-voltage line running down the cable itself. Using many wavelengths of light on each fibre, a single modern cable system can carry a staggering amount of data.
There are several hundred of these systems in service, landing at coastal stations and then linking inland by terrestrial fibre. Ownership has shifted over time: historically telecom consortia built them, but large cloud and content companies now own or co-own a significant share of new capacity.
Cables do break, mostly from accidental damage by ship anchors and trawling, and occasionally from undersea earthquakes and landslides. Repair ships locate the fault, grapple the cable up from the seabed and splice in a new section, which can take days to weeks depending on depth, weather and permits. Because most routes have alternatives, a single break usually causes slowdowns rather than blackouts, but some island nations and regions served by only one or two cables have suffered serious outages when theirs failed.
The shortcut that changed everything: CDNs and anycast
If every web request had to travel to a single origin server on the other side of the planet, the internet would feel sluggish. In reality, a lot of what you load comes from somewhere surprisingly close.
Content delivery networks (CDNs) keep copies of popular content on servers in hundreds of locations, often inside or next to ISPs and exchange points. When you request a video, image or script, DNS or routing tricks send you to a nearby copy. The long-haul journey happens once, when the CDN fetches the content, rather than once per viewer.
Many of these services also use anycast: the same IP address is announced via BGP from many locations at once. Each user's traffic naturally flows to whichever location their network considers closest in routing terms. The DNS root servers, for instance, are operated as many anycast instances spread around the world, which is a big part of why DNS is so resilient.
The net effect is that a large share of everyday traffic no longer crosses oceans at all. The "global" internet is increasingly a set of regional networks pre-loaded with the content people want.
Getting it there reliably: TCP, QUIC and congestion
Remember that the network core makes no promises. Reliability is added by transport protocols at the endpoints.
TCP, the long-standing workhorse, numbers every byte, has the receiver acknowledge what arrived, and retransmits anything lost. It also performs congestion control: it starts sending cautiously, speeds up while things go well, and backs off when packets start getting dropped, interpreting loss (or in newer variants, rising delay) as a sign that some link along the path is full. Congestion control is a quiet act of collective courtesy. Without it, everyone would blast data as fast as possible and shared links would collapse under the load, something that actually happened in the internet's early years before these algorithms were introduced.
QUIC, a newer protocol now used for much web traffic via HTTP/3, runs over UDP and builds in encryption and faster connection setup. It also handles multiple streams more gracefully, so one lost packet doesn't stall everything else.
Following the round trip
Putting it together, here's a simplified trip for loading a page hosted on another continent:
- Your laptop asks DNS for the site's address and gets back the address of a nearby CDN node, or of the origin if the content isn't cached.
- Packets go to your home router, then over your access line to your ISP.
- Your ISP's border routers consult their BGP tables and hand the packets to a peer at a local exchange point, or to a transit provider.
- If needed, the packets cross long-distance terrestrial fibre and a submarine cable, passing through routers in each network that make independent forwarding decisions.
- The destination network delivers the packets to the right data centre, the right rack and finally the right server.
- The server responds. The reply packets may take a different path back, since each network chooses its outbound routes according to its own policies. Asymmetric routing is normal.
The whole thing typically takes tens to a couple of hundred milliseconds for a round trip, depending on distance. Light in fibre travels at roughly two thirds of its speed in a vacuum, so geography sets a hard floor on delay that no amount of engineering can remove.
When routing goes wrong
The internet's decentralised trust model is both its strength and its weak point. BGP was designed in an era when the networks involved largely knew and trusted each other. By default, a router believes what its neighbours tell it.
That has led to some well-known incidents:
- Route leaks. A network accidentally re-announces routes it learned from one provider to another, suddenly attracting traffic it can't handle. Large chunks of traffic can be sent on bizarre detours or dropped.
- Hijacks. A network announces a prefix it doesn't own, or a more specific slice of it, and because routers prefer more specific routes, traffic is diverted. Sometimes this is a configuration mistake; there have been suspected deliberate cases too. A widely cited example from 2008 involved a national provider trying to block a video site domestically and accidentally announcing the block to the wider internet, making the site unreachable for much of the world for a couple of hours.
- Self-inflicted withdrawals. In 2021 a large social media company made a configuration change that withdrew the BGP routes to its own DNS servers. Its services vanished from the internet for several hours, and staff reportedly had trouble even accessing the buildings and tools needed to fix it, because those depended on the same internal systems.
The main defence being deployed is RPKI (Resource Public Key Infrastructure). Address holders publish cryptographically signed statements saying which AS numbers are allowed to originate their prefixes. Routers can then reject announcements that contradict those records. Adoption has grown substantially in recent years, with many large networks now filtering invalid routes, but it only validates the origin of a route, not the whole path. Extensions to validate paths exist but are at earlier stages. Operator groups also promote shared norms for filtering and coordination.
Who governs all this?
Nobody "runs" the internet, but some coordination is essential. IANA, operated under ICANN, oversees the global pools of IP addresses, AS numbers and the DNS root. Five regional internet registries allocate addresses within their regions. Technical standards like BGP, TCP and QUIC come out of the Internet Engineering Task Force, an open body where anyone can participate. Network operators coordinate informally through regional operator groups and mailing lists, which may sound quaint but is genuinely how a lot of incidents get fixed: someone posts "is anyone else seeing this?" and engineers from different companies start comparing notes.
Try it yourself
You can watch some of this in action with free tools:
traceroute(on macOS and Linux) ortracert(on Windows) lists the routers your packets pass through, with round-trip times for each hop. Try a site hosted far away and look for the jump in latency where you cross an ocean. Be aware that some routers don't respond, and that you're only seeing the outbound path.pingmeasures round-trip time to a host. Compare a nearby server with one on another continent and you'll see geography at work.nslookupordigshow DNS answers. Querying a big site from different networks (say, home broadband versus mobile data) can return different addresses, revealing CDN steering.- Public looking-glass services and BGP route viewers let you see how a prefix is announced from different vantage points around the world.
A few practical takeaways for everyday users:
- If one site is slow and others are fine, the problem is often a congested path or the destination itself, not your connection.
- Choice of DNS resolver can affect which CDN node you are directed to, which may affect speed, though the difference is usually small.
- Outages that take out a giant service usually come from configuration errors at that company, not from "the internet breaking".
Open questions
I'd love to hear what others think about a few things:
- As big content and cloud companies own more of the cables and peer directly with everyone, is the internet becoming more resilient, or more dependent on a handful of private networks?
- RPKI adoption has grown, but full path validation is still rare. Should regulators push for it, or is the industry's voluntary approach working well enough?
- For those who've run
tracerouteto somewhere distant: what surprised you about the path your data actually took?
