Skip to content
-
Subscribe to our newsletter & never miss our best posts. Subscribe Now!
  • https://www.facebook.com/
  • https://twitter.com/
  • https://t.me/
  • https://www.instagram.com/
  • https://youtube.com/
Cloud Security Tips Cloud Security Tips

What is cloud security

Cloud Security Tips Cloud Security Tips

What is cloud security

  • Home
  • About us
  • Contact us
  • Home
  • About us
  • Contact us
Subscribe
Close

Search

Black wireless router with multiple antennas, representing the Wi-Fi access points that use Hotspot 2.0 (Passpoint)
Tech

What Is VLSM?

By admin
November 19, 2026 7 Min Read
0

VLSM, or Variable Length Subnet Mask, is a way of dividing a network into subnets of different sizes so that IP addresses are not wasted. Instead of cutting a network into equal pieces, VLSM lets you give a large department a large subnet, a small team a small one, and a point-to-point link just two addresses. For anyone studying networking, preparing for a certification exam, or designing a real network, VLSM is the technique that turns subnetting from a textbook exercise into a practical skill.

In this guide, you will learn what VLSM is, how it differs from fixed-length subnetting, how to work out subnet sizes, and how to apply it in a worked example. No advanced mathematics is needed — just powers of two and a little patience.

Table of Contents

Toggle
  • What Is VLSM?
  • VLSM vs. Fixed-Length Subnetting (FLSM)
  • How VLSM Works: The Maths
  • Worked Example: Subnetting 192.168.1.0/24 with VLSM
    • Step 1: Sort the requirements, largest first
    • Step 2: Sales — 50 hosts
    • Step 3: Engineering — 25 hosts
    • Step 4: HR — 12 hosts
    • Step 5: WAN link — 2 hosts
  • Benefits of VLSM
  • Limitations and Pitfalls
  • Design Tips for Using VLSM
  • Frequently Asked Questions
    • What does VLSM stand for?
    • What is the difference between VLSM and FLSM?
    • Which routing protocols support VLSM?
    • When should I use VLSM?
  • Conclusion

What Is VLSM?

VLSM stands for Variable Length Subnet Mask. It is a subnetting technique in which different subnets in the same network use different subnet masks — and therefore have different sizes. A /26 subnet has 62 usable host addresses, a /28 has 14, and a /30 has just 2. With VLSM, each subnet gets a mask that matches the number of hosts it actually needs.

The idea only works with classless addressing, where the boundary between the network part and the host part of an address can fall anywhere. That is the world of CIDR (Classless Inter-Domain Routing), in which an address is written with a prefix length, such as 192.168.1.0/24. What is an IP address? In short, it is a 32-bit number that identifies a device on a network, and the subnet mask says how much of that number identifies the network and how much identifies the device.

VLSM vs. Fixed-Length Subnetting (FLSM)

Before VLSM, networks used fixed-length subnetting (FLSM): every subnet in a network had the same size. That is simple, but wasteful.

Suppose you have the network 192.168.1.0/24 — 256 addresses — and you need subnets for 100, 50, 20, and 5 hosts. With FLSM, the largest requirement decides the size for all of them. A subnet for 100 hosts needs at least 128 addresses, so every subnet is carved into /25 blocks of 128 addresses. The subnet for 5 hosts would still get 128 addresses, wasting more than 120 of them, and you would only get two subnets out of the whole network.

With VLSM, each requirement gets a right-sized subnet: a /25 for the 100 hosts, a /26 for the 50, a /27 for the 20, and a /29 for the 5. The same 256 addresses now serve all four groups, with room to spare. That is the whole point of VLSM: fit the subnet to the need.

How VLSM Works: The Maths

Every subnet calculation comes down to powers of two. Each host bit doubles the number of addresses in a subnet, and two addresses in every subnet are reserved: the network address and the broadcast address.

  • A /24 network has 8 host bits: 2^8 = 256 addresses, 254 usable.
  • A /25 has 7 host bits: 128 addresses, 126 usable.
  • A /26 has 6 host bits: 64 addresses, 62 usable.
  • A /27 has 5 host bits: 32 addresses, 30 usable.
  • A /28 has 4 host bits: 16 addresses, 14 usable.
  • A /29 has 3 host bits: 8 addresses, 6 usable.
  • A /30 has 2 host bits: 4 addresses, 2 usable — the standard size for a point-to-point link between two routers.

To size a subnet, find the smallest power of two that covers the hosts you need plus the two reserved addresses. For 50 hosts, you need at least 52 addresses, so the next power of two is 64 — a /26, with 62 usable addresses. For 12 hosts, you need at least 14 addresses, so the next power of two is 16 — a /28, with 14 usable addresses.

A subnet is a smaller network carved out of a larger one. VLSM is simply the practice of carving subnets of different sizes from the same parent network, in order, largest first.

Worked Example: Subnetting 192.168.1.0/24 with VLSM

Here is a complete example. A small company has the network 192.168.1.0/24 and needs four subnets: Sales with 50 hosts, Engineering with 25 hosts, HR with 12 hosts, and a WAN link between two routers with 2 hosts.

Step 1: Sort the requirements, largest first

Always start with the largest subnet. If you start small, you can end up with the larger subnets not fitting into the remaining space. The order is Sales (50), Engineering (25), HR (12), WAN link (2).

Step 2: Sales — 50 hosts

50 hosts need 52 addresses, so the next power of two is 64: a /26 subnet. The first available block is 192.168.1.0/26. It covers 192.168.1.0 to 192.168.1.63, with usable addresses from 192.168.1.1 to 192.168.1.62. The network address is 192.168.1.0 and the broadcast address is 192.168.1.63.

Step 3: Engineering — 25 hosts

25 hosts need 27 addresses, so the next power of two is 32: a /27 subnet. The next free block starts at 192.168.1.64, so Engineering gets 192.168.1.64/27, covering 192.168.1.64 to 192.168.1.95, with usable addresses from 192.168.1.65 to 192.168.1.94.

Step 4: HR — 12 hosts

12 hosts need 14 addresses, so the next power of two is 16: a /28 subnet. The next free block starts at 192.168.1.96, so HR gets 192.168.1.96/28, covering 192.168.1.96 to 192.168.1.111, with usable addresses from 192.168.1.97 to 192.168.1.110.

Step 5: WAN link — 2 hosts

A point-to-point link needs just 2 usable addresses, so a /30 is perfect. The next free block starts at 192.168.1.112, so the WAN link gets 192.168.1.112/30, covering 192.168.1.112 to 192.168.1.115, with usable addresses 192.168.1.113 and 192.168.1.114.

The four subnets together use addresses 192.168.1.0 to 192.168.1.115. The remaining space, 192.168.1.116 to 192.168.1.255, is still free for future growth — with FLSM, it would have been wasted.

Benefits of VLSM

  • It saves IP addresses. Small subnets stop wasting addresses on links and teams that need only a few hosts, which matters most when address space is limited.
  • It matches real networks. Real organisations have departments of very different sizes, and VLSM reflects that instead of forcing every group into the same size.
  • It supports route summarisation. Because VLSM subnets are carved from one parent network, routers can often advertise a single summary route for the whole block, keeping routing tables smaller.
  • It is the standard for modern networks. Classless routing protocols and modern network design assume VLSM; it is not an optional extra.

Limitations and Pitfalls

VLSM is not free of trade-offs. First, it is more complex than fixed-length subnetting. A mistake in one calculation can create overlapping subnets, where two subnets claim the same addresses, and the network will behave unpredictably. Second, it needs classless routing protocols: older classful protocols such as RIPv1 do not advertise subnet masks, so they cannot support VLSM. Modern protocols such as OSPF, EIGRP, and RIPv2 do. Third, VLSM designs need to leave room for growth. A subnet sized exactly for today’s headcount will break the day a department hires one more person, so most designers add a margin of 10 to 20 percent.

Design Tips for Using VLSM

  • Always allocate largest first. This keeps the address space tidy and avoids fragmentation.
  • Leave growth space. Size each subnet for the hosts you expect in the next year or two, not just today.
  • Document every subnet. Record the network address, mask, range, and purpose of each subnet in an IP address management (IPAM) tool or a simple spreadsheet.
  • Reserve space for infrastructure. Keep blocks aside for servers, printers, management interfaces, and future sites.
  • Use /30 (or /31) for point-to-point links. Two routers on a link need only two addresses; giving them a /24 is a waste.
  • Check for overlap before deploying. A subnet calculator or a quick check of the ranges will catch overlapping subnets before they reach production.

Network Address Translation (NAT) is a separate technique that lets private addresses reach the internet, but the same discipline applies: plan your addressing, document it, and leave room to grow.

Frequently Asked Questions

What does VLSM stand for?

VLSM stands for Variable Length Subnet Mask. It is a subnetting method in which different subnets in the same network use different subnet masks, so each subnet can be a different size.

What is the difference between VLSM and FLSM?

FLSM (Fixed Length Subnet Mask) gives every subnet the same size, which wastes addresses when requirements differ. VLSM gives each subnet a size matched to its needs, so address space is used efficiently.

Which routing protocols support VLSM?

Classless routing protocols support VLSM, including RIPv2, EIGRP, and OSPF. Classful protocols such as RIPv1 do not advertise subnet masks and cannot support it.

When should I use VLSM?

Use VLSM whenever a network has subnets of different sizes, when IP address space is limited, or when you are designing a network from scratch. For a network where every subnet genuinely needs the same number of hosts, FLSM is simpler and perfectly fine.

Conclusion

VLSM is one of those ideas that looks complicated until you work through one example, and then it becomes obvious. Fixed-length subnetting wastes addresses; variable-length subnetting fits each subnet to its need, largest first, using the smallest power of two that covers the hosts plus the network and broadcast addresses. Learn the powers of two, practise the worked example above with your own numbers, and you will be able to design efficient, documented, and scalable networks — and answer the VLSM questions on any networking exam with confidence.

Author

admin

Follow Me
Other Articles
Blue shield emblem with a padlock, representing compliance risk assessment and information security governance
Previous

What Is PHI in Medical Terms?

Magnifying glass inspecting red computer code for a hidden security flaw
Next

What Is a Zero Day? Definition, Examples, and How to Protect Yourself

No Comment! Be the first one.

    Leave a Reply Cancel reply

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

    Recent Posts

    • Compliance Risk Assessment: A Complete Guide for 2026
    • SX SFP Module: What It Is, How It Works, and When to Use It
    • Hotspot 2.0 (Wi-Fi Passpoint): What It Is and How It Works
    • Volume Boot Record (VBR): What It Is, How It Works, and How to Fix It
    • Can Website Owners See Who Visits Their Website? What They Can (and Cannot) See

    Recent Comments

    1. Compliance Risk Assessment: A Complete Guide for 2026 on ISO 27001 Compliance: What It Is, How to Get Certified, and How to Stay Compliant
    2. SX SFP Module: What It Is, How It Works & When to Use It on Network Access Control: What It Is, How It Works, Types and Examples
    3. Hotspot 2.0 (Wi-Fi Passpoint): What It Is & How It Works on WIPS: What Is a Wireless Intrusion Prevention System?
    4. Volume Boot Record (VBR): What It Is & How to Fix It on Hypervisor: What It Is, Types, Security Risks and How to Harden It
    5. Can Website Owners See Who Visits? What They See & Can't See on California Consumer Privacy Act (CCPA): What It Is, Your Rights, and How to Comply in 2026

    Archives

    • November 2026
    • October 2026
    • September 2026
    • August 2026
    • July 2026
    • June 2026
    • May 2026
    • February 2026

    Categories

    • Blog
    • Business
    • Security Tips
    • Tech
    • Travel
    • Uncategorized
    Copyright 2026 — Cloud Security Tips. All rights reserved. Blogsy WordPress Theme

    Powered by CookieAdmin
    Necessary cookies enable essential site features like secure log-ins and consent preference adjustments. They do not store personal data.
    None
    Functional cookies support features like content sharing on social media, collecting feedback, and enabling third-party tools.
    None
    Analytical cookies track visitor interactions, providing insights on metrics like visitor count, bounce rate, and traffic sources.
    None
    Advertisement cookies deliver personalized ads based on your previous visits and analyze the effectiveness of ad campaigns.
    None
    Unclassified cookies are cookies that we are in the process of classifying, together with the providers of individual cookies.
    None
    Powered by CookieAdmin