← Networking

How data travels

Protocols and packets

协议与数据包

A protocol is a set of rules devices agree on so they can understand each other; TCP/IP, the basis of the internet, is the best known.

Data is split into small pieces called packets; each travels across the network and they are put back together on arrival.

Protocols are organised in layers, each with its own job: the application layer, such as HTTP for websites; the transport layer, such as TCP to ensure delivery; and the network layer, such as IP for addressing and routing.

TCP makes sure all packets arrive in order and resends lost ones, so it is used for websites and email. UDP is faster and doesn't resend, so it is used for video calls and games where speed matters more.

Each packet carries the sender's and receiver's addresses and a number showing its order. Packets may take different routes, and the receiving device puts them back together like puzzle pieces.

Ask the AI assistant

Ask anything about this lesson and get a simple answer with the terms in Chinese, Arabic and English.

The AI assistant runs on Google's Gemini model and can make mistakes. Do not write personal information. Available to signed-in learners, up to 30 requests a day.

The content is simplified and covers the basics only.