💻 Computer Science · Topic 59 of 80

Packets and Routing

Data is split into packets that travel independently.

Interactive labFollow the idea step by step

About this topic

Data sent over the Internet is split into small units called packets. Each packet contains a header with the source and destination IP addresses, a sequence number and error-checking information, plus part of the data. Packets are sent independently across the network and reassembled at the destination.

Routers are devices that read each packet's destination address and forward it to the next router that is closer, using routing tables. Different packets of the same message may take different paths, may arrive out of order, or may be lost, so TCP puts them back in order and requests resends of missing ones. A time-to-live value is reduced at every hop, so packets stuck in loops are eventually discarded.

This packet switching design is more efficient and robust than reserving a dedicated line, as in old telephone circuits, because many conversations share the same links and traffic can route around broken connections. For example, a photo sent by email is split into hundreds of packets. A common misconception is that a file travels as one block. Tools like traceroute show the hops your data takes. Delays in the path create latency.

Key ideas

  1. Headers carry addresses
  2. Routers choose paths
  3. Reassembled at the destination

Quick check

Use cases: where Packets and Routing helps

Computing ideas run phones, search engines, games and the wider internet.

Frequently asked questions

What is Packets and Routing?

Data is split into packets that travel independently.

What will I learn in Packets and Routing?

Headers carry addresses. Routers choose paths. Reassembled at the destination.

Is Packets and Routing part of Computer Science?

Yes. It is one of 80 Computer Science topics on LearnViz HighSchoolEdu, with 3 key ideas, a live animation and a quick check.

Does the Packets and Routing lab work on a phone or tablet?

Yes. The animation resizes to fit your screen and supports touch, so you can drag, tap and slide with your finger.

How should I study Packets and Routing?

Read the summary and key ideas first, play with the interactive lab to see the idea in motion, then answer the quick check. If you get a question wrong, go back to the key idea it tests.

Do I need an account, and is my progress saved?

No account is needed. Marking a topic as learned is saved in your own browser, so it stays on that device and is not sent to a server.

More in Computer Science