Explain like I'm five · Network

What is an L4 Switch?

An L4 switch, told as a story about a sorter who reads the counter number too, not just the town name, when handing off packages.

Town 12Town 12the sorter only reads the town name, then tosses the envelope to any counterthe same town has separate counters for web vs mail — but the envelopes get mixed up

The sorter only reads the town name, then tosses the envelope to any counter.The same town has separate counters by purpose — but the envelopes get mixed up.

counter 80mine is urgentcounter 25mine can waitthe town name alone can't tell the counter-80 envelope from the counter-25 one

Different counters need different speed and priority.The town name alone can't tell the counter-80 envelope from the counter-25 one.

8044325L4 switch = a sorter who reads the counter number (port) too, not just the townan L4 switch splits the path by purpose, even within the same town

An L4 switch = a sorter who reads the counter number (port) too.An L4 switch splits the path by purpose, even within the same town.

Check the Portreads the counter number
Spread Evenlyno pile-up at one counter
Priorityurgent counters go first
Health Checkavoids a closed counter
WHAT DOES EACH DEVICE READL2 switch — reads only the neighboring building's own tag (MAC)L3 router — reads the town name (IP address) tooL4 switch — reads the counter number (port) too, and spreads the loadload balancing — spreads work evenly across same-type counters

Devices at each layer read different information.L4 reads the port too and spreads load evenly across same-type counters (load balancing).

an L4 switch reads the counter number fastbut it can't read inside the envelope (an L7 job)reading what's inside the envelope is an L7 device's job

An L4 switch can't read what's inside the envelope.Reading what's inside the envelope is an L7 device's job.

In one breath

L4 switch = a sorter that reads the counter number (port) too, not just the town (IP), spreading traffic evenly across same-purpose counters.

An L4 switch distributes traffic by also referencing OSI Layer 4 (transport layer) information — TCP/UDP port numbers. Compared to L3 routing, which only sees IP addresses, it load-balances more precisely by service and session, but it doesn't inspect the packet's content (application data) itself.

When grown-ups say it

Port Number
Which counter inside the building. Distinguishes services at the same address.
Load Balancing
Spreading work evenly across same-type counters. A signature use of an L4 switch.
L2/L3/L4
Neighbor, town, counter number — each layer sees a wider scope. Layers 2 through 4 of the OSI 7-layer model. → the delivery process split into 7 stages
Transport Layer
The stage that handles ports and the registered/plain choice. The very layer an L4 switch references. → the stage that splits ports and picks reliability
Traffic Shaping/Policing
The rule controlling intake at each counter. A rule applied once counters are split this way. → the counter that controls the flow
Subnetting
Splitting a town into smaller zones. The L3-level story of splitting a town. → splitting the town into smaller zip-code zones
WAF/L7 Device
A device that reads inside the envelope too. A topic covered in the Security field.
Network IPC
The dedicated mailbox that picks its target by port. A concrete example of using port numbers. → the dedicated mailbox between processes
Next story
The Network Where Meters Mail Their Own Readings →
Want another term as a picture book? Request →