Routing·Lesson 1 of 13
Routing
The Short Answer
Routing is the process of choosing the path that data takes to travel from where it starts to where it needs to go, across many connected networks. When you load a website, your data does not leap straight to the server in one jump — it is broken into small chunks called , and each packet hops from one network to the next until it arrives. At every step, some device has to decide which way to send it. That decision is routing.
The one-line version
Routing means choosing the path a packet should take across networks. It is done by routers, which read each packet's destination address and decide where to send it next.
Like a GPS on a road trip
A GPS does not pick up your car and drop it at the destination. It guides you one turn at a time: at each intersection it tells you the best next road to take, based on where you are heading. Routing works the same way — at each junction in the network, a router points your data toward the next best step on its journey.
Who Does the Routing?
The devices that do routing are called . A router is a piece of hardware whose job is to connect different networks together and pass data between them. Every packet carries a destination — a numeric label saying which device, on which network, it is trying to reach. The router reads that address and decides the best next step to move the packet closer to its goal.
Hop by Hop
Here is the key idea that surprises most beginners: no single router knows the whole path to the destination. Each router only decides the — the very next device to hand the packet to. The packet travels one hop at a time, and each router along the way nudges it closer, until it finally reaches the destination network. A is just one step from one router to the next.
Between any two points on the internet there are usually many possible paths, like a web of roads connecting cities. Routing is what picks a good one. This mesh of interconnected routers is what makes the internet resilient — if one link fails, another path can often be found:
Routing vs Forwarding
Two words often get mixed up: routing and forwarding. Routing is the thinking part — working out and remembering which direction leads to each destination, and storing those decisions in a lookup table. Forwarding is the doing part — the split-second action of taking a packet that just arrived and sending it out the correct port toward the next hop. Routing builds the plan; forwarding carries it out.
| Routing | Forwarding | |
|---|---|---|
| What it is | Deciding the best paths | Moving a packet to the next hop |
| When it happens | Ahead of time, and on changes | The instant a packet arrives |
| Result | A routing table of known paths | A packet sent out the right port |
| Analogy | Planning the route on a map | Actually driving to the next turn |
Two Ways to Build Routes
How does a router learn which way to send packets? There are two approaches. With , a human administrator types in the routes by hand. With , routers talk to each other and learn the routes automatically, updating themselves when the network changes. Most large networks rely on dynamic routing, while static routes are handy for small or simple setups.
“"A packet knows its full route before it leaves your device."”
Q:What is the difference between routing and forwarding?
A: Routing is the process of determining the best paths to destinations and recording them in a routing table — it is the decision-making. Forwarding is the action of moving an individual packet from an incoming port to the correct outgoing port toward its next hop, using that table. In short: routing builds the map, forwarding follows it.
Quick Revision Cheat Sheet
Routing: Choosing the path a packet takes across networks
Done by: Routers, using each packet's destination IP address
Hop by hop: Each router decides only the next hop, not the full path
Routing vs forwarding: Routing plans the path; forwarding moves the packet
Static vs dynamic: Routes set by hand vs learned automatically