A network switch links computers, printers, and other devices on a local area network. It learns MAC addresses and sends each Ethernet frame to the right port, helping separate conversations flow smoothly. Unlike a hub, it doesn’t broadcast every message to every device.

Multiple Choice

In a LAN, what component connects multiple devices?

Within a LAN, the device that links multiple devices together is the switch. A switch operates by learning each connected device’s MAC address and building a table of which port that address can be reached on. When a frame arrives, the switch looks up the destination MAC and forwards the frame only to the port that leads to that device. If it doesn’t know where a destination MAC is yet, it floods the frame to all ports except the sender, and then quickly learns as responses come back. This creates a separate collision domain per connection and allows multiple conversations to happen at the same time without interfering with each other. A hub, by comparison, simply repeats incoming signals to all ports, so every device shares the same collision domain and bandwidth, which leads to more collisions and less efficient use of the network. A router connects the LAN to other networks and handles inter-network routing, not just devices within a single local network. A modem serves as the interface to an internet service provider, not as the device that interconnects multiple hosts within the LAN.

How a Switch Connects Devices on a Local Network

A laptop sends a photo to a printer across the room. A phone streams music while a desktop backs up files. These devices may seem to be doing separate jobs, yet they can share one local network, or LAN, because a central piece of equipment helps them communicate: a network switch.

A switch links devices on a LAN and sends data to the place it needs to go. That sounds simple, but the way it handles traffic makes a big difference. Instead of sending every message to every connected device, a switch learns where devices are and directs traffic toward the right connection. Think of it as a mailroom that remembers which desk belongs to which person.

The switch keeps track of who’s connected

Devices on an Ethernet network use hardware identifiers called MAC addresses. A MAC address is tied to a network interface, such as the Ethernet port in a computer. It works at the local network level, helping devices distinguish one another even when they share the same physical cables.

A switch learns these addresses as devices send data. When a frame arrives at one of its ports, the switch notes the sender’s MAC address and the port where it arrived. It stores that information in a MAC address table.

The table is a little like a building directory. If the switch later receives a frame meant for a device it knows, it checks the destination MAC address, finds the matching port, and forwards the frame there. The other connected devices don’t need to receive it.

That targeted delivery helps keep network traffic orderly. A computer copying a file to a network printer won’t automatically send that file to every other computer on the same switch. It’s a small detail with a useful result: devices can communicate without making every connection listen to every conversation.

What happens when the switch doesn’t know the destination?

A switch may not have a destination address in its table yet. That can happen when a device has just joined the network or has been quiet for a while. In that case, the switch sends the frame out through all ports except the one it came in on. This is called flooding.

The switch isn’t guessing wildly; it’s helping the frame find its destination. When the destination device replies, the switch learns which port leads to it. From then on, it can send frames for that address directly to the right connection.

This learning process happens in the background. Users usually don’t notice it. A new device might take a moment to become known to the switch, but the table fills in as ordinary network traffic flows.

Why a switch makes traffic more efficient

Older Ethernet networks sometimes used hubs, which sent incoming signals out through every port. That meant all connected devices shared the same bandwidth and collision domain. If two devices sent data at once, their signals could interfere, much like two people trying to speak over each other on a crowded call.

A switch handles traffic differently. Each switch port forms its own collision domain, so devices connected to separate ports don’t compete for the same shared collision space. In modern Ethernet networks, links commonly use full-duplex communication: a device can send and receive data at the same time. Collisions are therefore far less of a concern than they were on older shared networks.

Still, the broader idea matters. A switch gives each connected device a more direct path for local traffic, rather than making every device share one channel. Multiple conversations can move through the network at once, as long as the switch and its links have room to carry them.

That doesn’t mean a switch can make a slow network magically fast. The speed of its ports, the quality of the cables, the capacity of the connected devices, and the amount of traffic all matter. But by forwarding frames to the relevant ports, a switch avoids needless traffic and helps the LAN use its capacity well.

A switch and a hub aren’t the same thing

Hubs are now mostly a piece of networking history, but they’re useful for understanding what switches do. A hub repeats an incoming electrical signal to all its ports. It doesn’t read MAC addresses or decide where a frame should go.

That simplicity comes at a cost. Every connected device shares the same collision domain, and each one receives traffic that may not be meant for it. On a busy network, this can lead to congestion and wasted bandwidth. A switch, by contrast, learns device addresses and forwards known traffic to the appropriate port.

A hub is like announcing every message over a loudspeaker. A switch is more like handing each message to the right person. The comparison isn’t perfect, but it captures the key difference.

Where routers and modems fit in

Switches, routers, and modems often sit close together in a home or school network, so it’s easy to mix up their roles. Each one handles a different part of the connection.

A switch connects devices within a LAN. A router moves traffic between networks. For example, when a laptop sends a request to a website, the router helps the traffic leave the local network and reach another network, such as the wider internet. It also uses IP addresses to guide traffic between those networks.

A modem connects a home or building to an internet service provider’s network. The type of modem depends on the service: cable, DSL, and fiber connections use different equipment and technologies. In many homes, one box combines a modem, router, and switch, which can make the jobs seem like one function. They’re still distinct roles, even when they share a case.

Here’s an everyday way to picture it: the switch connects rooms inside a building, the router directs deliveries between buildings, and the modem provides the link to the road outside. Real networks are more complex, of course, but the image helps keep the roles straight.

One LAN can contain more than one switch

A LAN doesn’t have to stop at a single switch. Schools, offices, and larger homes may use several switches to connect devices in different rooms or areas. Those switches can link to one another, extending the network while keeping each device connected to the local system.

Network teams may also use VLANs, or virtual LANs, to separate groups of devices on shared switch hardware. A school could place staff computers, student devices, and printers in separate VLANs. This helps control which groups can communicate and can make a network easier to manage. A VLAN is a logical separation, not a separate physical switch for every group.

So, a switch is more than a box with a row of Ethernet ports. It learns which devices are reachable through which connections, then forwards local traffic accordingly. That quiet bit of bookkeeping lets computers, printers, phones, and other devices share a LAN without every message being broadcast to everyone. In a busy network, that’s what keeps the conversation moving.