KS3 · Computer Science

How the internet routes data

Type a website's name and press enter. Before the page appears, your request goes on a journey: a name becomes a number, and the number says where to go.

Computer Science · Networks

Follow one web request

A first visit to a website, one hop at a time.

First visit to a website. Before you press Next: who do you think gets asked first?

Message: Please send me this website's page

Your browser→ISP's DNS server→Root DNS server→TLD server→Authoritative name server→Website's server
Answer=No, this is a first visitQuestion=Do I already know this website's IP address?

Output

 

Step 1: Your browser starts by checking whether you've visited this website before, in case it already knows the IP address. On a first visit it doesn't, so it has to go and find out.

1 / 7

Press Next to follow the request. Every step is written out in advance; the page isn't running a real lookup.

Step 1 of 7: Your browser starts by checking whether you've visited this website before, in case it already knows the IP address. On a first visit it doesn't, so it has to go and find out..

Computer Science · Structure

A home network, joined up

Tap each part to see its job.

Your home networkpublic IP

Tap any part of the diagram to see what it does.

Check your thinking

Who has which address?

A phone, a laptop and a games console are all online in the same home at the same time.

Which idea is closest to what you think right now?
How sure are you?

Two address services, two different jobs

DHCPvsDNS

DHCP and DNS get mixed up all the time. Read the first row twice.

Focus

What it does

DHCP

Assigns IP addresses automatically

DNS

Converts domain names into IP addresses

The insight

DHCP hands out addresses. DNS turns a name into an address that already exists.

Stands for

DHCP

Dynamic host configuration protocol

DNS

The domain name system

Who uses it

DHCP

The ISP gives the router its public address. The router gives devices their private addresses.

DNS

Your computer asks DNS servers when it doesn't already know a website's IP address.

What it gives you

DHCP

An address for a device, so it can send and receive data

DNS

The address of a website, so devices know where to send data

Your turn

Which route does the data take?

A router can send data along three routes. Route one has links costing 5 and 5. Route two has links costing 5, 3 and 6. Route three has links costing 3 and 6. Which route is used?

  1. A route's cost is a measure of how suitable the route is. It can depend on latency (time delay), bandwidth availability, reliability and congestion. The router adds up the link costs on each route.Routing algorithms calculate the total cost for different routes and choose the one with the lowest cost.
  2. Route one: 5 + 5 = 10
  3. missing step
Which line is step 3?

Why routing matters

?

Reason it through

Why does efficient routing matter for a network?

Link 1 of 4

First link · your turn

Routers choose the best path for data. What kind of path are they looking for?

2
Locked — reveal the link above first
3
Locked — reveal the link above first
4
Locked — reveal the link above first

WHAT YOU'VE LEARNED

A quick recap of today's lesson.

A name becomes a number, and the number says where the data goes.

What you need to know

  • An IP address is a unique number that identifies a device on a network, a bit like a house address, so data reaches the right device.
  • On a local network, each device needs its own unique private IP address.
  • To reach the internet, the router uses a public IP address, so all the devices in a home share one public address.
  • Your ISP assigns the public IP address to your home network, and acts as the gateway to billions of other devices.
  • DHCP assigns IP addresses automatically: public to the router from the ISP, private to devices from the router.
  • Have a goSam says your ISP hands every device in your house its private IP address. Sam is confidently wrong. Who really does it?

    The router, acting as a DHCP server.

    The ISP uses DHCP to give the router its public address. The router then gives each device a private address when it joins.

  • DNS converts a domain name into an IP address, so devices know where to send data.
  • Your browser first checks whether it already knows the IP address from an earlier visit. If not, it uses DNS.
  • Have a goYou've visited a website before. What does your browser try first: asking DNS, or checking what it already knows?

    Checking whether it already knows the IP address.

    It does that check before going out to use DNS. DNS is needed when you haven't visited the site before.

  • Your computer typically asks your ISP's DNS server first, then goes up to the root DNS server, a TLD server and the authoritative name server.
  • A router moves data from one network to another. Routing is routers choosing the best path, using sets of rules called routing protocols.
  • Each route has a cost. Routers add up the link costs and choose the route with the lowest total.
  • Have a goRoute A has links costing 4 and 4. Route B has links costing 2 and 7. Which route does the router choose?

    Route A, with a total of 8 (Route B totals 9).

    Routers pick the lowest total cost. Choosing the bigger total, or whichever is listed last, gets it wrong.

The big picture

Getting a web page is a chain of look-ups and hand-offs. Devices have IP addresses, DNS turns a domain name into an IP address, and routers choose the lowest-cost route so the data reaches the right place along an efficient path.

Key points

1Each device on a local network has a unique private IP address; the devices in a home share one public IP address when they communicate on the internet.
2The ISP assigns the public IP address; DHCP assigns IP addresses automatically.
3DNS converts domain names into IP addresses so devices know where to send data.
4A router moves data between networks, and routing means routers choose the best path using routing protocols.
5Routers add up the link costs on each route and choose the lowest total.

Worked example

Problem

Priya's home has a tablet, a TV and a laptop online. How many private and how many public IP addresses are in use, and who assigned each?

⚠ Watch out

Thinking each device in a home has its own public IP address on the internet. Each device has a unique private address on the local network, and the devices share one public address.

🧠

Memory hook

Name, number, route, page: DNS turns the name into a number, and routers pick the lowest-cost route to carry the data there.

✓

Check yourself

Without looking back: for a first visit, put these in order: root DNS server, authoritative name server, ISP's DNS server, TLD server.

Flashcards

(14)
What is an IP address?
A unique number assigned to each device on a network. It identifies the device and lets it send or receive data.
What does each device on a local network need?
A unique private IP address.
Private or public: which kind of IP address is shared by every device in a home?
The public one, used by the router for the internet.
Who assigns a home network's public IP address?
The ISP, which also acts as the gateway to billions of other devices.
What does DHCP do?
Dynamic host configuration protocol: it assigns IP addresses automatically.
What does DNS do?
The domain name system converts domain names into IP addresses.
What does your browser check before it goes out to use DNS?
Whether it already knows the website's IP address from a previous visit.
On a first visit, which DNS server does your computer typically check first?
Your ISP's DNS server. If the address isn't there, the request goes up the hierarchy.
Which server sits at the very top of the DNS hierarchy, and what does it do?
The root DNS server. It directs the request to the correct TLD server.
What does an authoritative name server (ANS) do?
It gives your computer the specific IP address for the website, so your browser can connect to the server.
What is a router?
A device that manages the flow of data between networks. It commonly connects a local network to the internet.
What is routing?
Routers selecting the best path for data across a network, using routing protocols: sets of rules for finding the most efficient route.
What is a route's cost, and what can it depend on?
A measure of how suitable the route is. It can depend on latency, bandwidth availability, reliability and congestion.
Why does efficient routing matter?
Data takes the quickest path, so transfers are faster and congestion is reduced. The network performs better and stays reliable and responsive as demand grows.

Tap any card to flip it, or use Study as deck to go through them one at a time. In the full lesson these run as a spaced-repetition deck — you rate each card Hard, Good or Easy and the tricky ones keep coming back until they stick.

Learning with Lightbulb is opening soon

You can use this lesson now. Join the waitlist and we'll let you know when the full Lightbulb experience is ready.

Keep me posted

More KS3 Computer Science topics

See the full KS3 Computer Science curriculum →

How this lesson was checked. This KS3 Computer Sciencelesson was published through Lightbulb Learning's human-designed editorial process — the educational standards, accuracy rules and publication checks it must pass were authored and approved by Philip Halpin. It passed subject-specific assessment, automated educational checks and technical publication verification before going live (publication checks completed 10 November 2026). Published pages are monitored, human spot-checking is ongoing across the lesson library, and anything found wrong is corrected or withdrawn. How our lessons are made and checked. Spotted a mistake? Email hello@lightbulblearning.co and we'll review it.

Helpful guides for parents and students