Networking Hardware Software

What are Subnets in a Router?

Your Network: A Big Apartment Building

Your internet router is like the main lobby of an apartment building. It’s the gateway for devices to join the party (your network) and to venture outside into the wider internet.

Each device on your network (computers, phones, smart TVs, etc.) is like a resident of the building, needing a unique apartment number to be located. These are the IP addresses.

Subnets: Dividing the Building into Floors

A large apartment building gets chaotic if everyone’s crammed onto one floor. Subnets are like dividing your network into smaller and more manageable floors within the building.

Why do this?

Efficiency: Traffic meant for devices on the same floor (subnet) stays local instead of everyone shouting across the whole building. This first and foremost improves the performance of the network.

Organization: You might have a floor for guest devices, another for smart home gadgets, one for work machines. Subnets keep these things properly separated.

Security: Subnets will help isolate sensitive devices or restrict what certain parts of your network can talk to each other.

Technical Bits: How Subnets Work

Subnet Mask: This is like the code that tells devices which floor (subnet) they belong to. A typical home subnet mask will be

IP Address Magic: Devices and your router do some quick math comparing their IP addresses with the subnet mask. If the results match then they’re on the same subnet.

In Your Router’s Settings

Most home routers don’t make you interfere with subnets directly. Their default setup is a single and large subnet for all your devices.

More advanced routers and managed switches will give you the option to define custom subnets. This is more common in businesses or for tech enthusiasts with complex network needs.

Real-World Examples:

Guest Wi-Fi: Your router will create a separate subnet for your Guest Wi-Fi network. This will isolate guests from your main devices. It’s a pretty good security option

IoT Devices: You can put sketchier devices (security cameras, smart bulbs, etc.) on their own subnet for extra security.

Small Business: A business can have different subnets for employees, customers and sensitive internal systems to avoid the leak of information.

Subnet Math: Unveiling the Mystery

IP addresses and subnet masks are expressed as four sets of decimal numbers between 0 and 255 (e.g.,, But behind the scenes they’re also binary numbers (lots of 0s and 1s). The subnet mask defines how many bits in an IP address identify the network (subnet) part and how many bits identify the specific host (device) on that network.

Convert the Decimal Mask to Binary:

For example, our common home subnet mask of translates to: 11111111.11111111.11111111.00000000 (in binary)

Matching Bits = Same Subnet:

Any two IP addresses on your network will have the same bits wherever the subnet mask has a 1. The remaining bits (where the mask is 0) define the specific device on the network.


  • Subnet mask: (binary: 11111111.11111111.11111111.00000000)
  • Device 1 IP: (binary: 11000000.10101000.00000001.01100100)
  • Device 2 IP: (binary: 11000000.10101000.00000001.10010110)

As you can see both devices share the same bits where the subnet mask is 1s, indicating they belong to the same subnet (

CIDR Notation: A Shorthand

CIDR (Classless Inter-Domain Routing) notation is a concise way to represent subnet masks. It combines the IP address with a forward slash and the number of leading 1s in the subnet mask’s binary form.

For example, our previous scenario with a subnet mask would be written as (24 bits are set to 1 in the binary mask).

Advanced Router Configurations: Multiple Subnets in Action

While most home routers handle a single subnet for basic needs, advanced routers or managed switches allow you to create custom subnets.

  • Security Segmentation: Isolate guest Wi-Fi or Internet of Things (IoT) devices on their own subnets restricting their access to sensitive resources on your main network.
  • VLANs (Virtual LANs): Create logical subnets that can span physical network ports. Useful for grouping devices by department or function in a business environment.
  • Denial-of-Service (DoS) Protection: Isolate critical systems on a separate subnet to minimize the impact of a DoS attack on other parts of the network.

Configuring Subnets on Your Router

The specifics of creating subnets will vary depending on your router model. But generally you’ll find the options under “LAN Settings” or “Advanced Networking” in your router’s web interface. You’ll need to define:

  • Subnet Address: The base IP address for the new subnet (e.g., for a second subnet).
  • Subnet Mask: The subnet mask that defines the subnet size (e.g., for a typical /24 subnet).

Leave a Reply

Your email address will not be published. Required fields are marked *