Ever wondered what is a subnet mask? If you've poked around in your Wi-Fi settings or tried to troubleshoot your network, you've probably seen something like 255.255.255.0 next to your IP address — and thought, "What does that even mean?" You're not alone. Subnet masks look cryptic, but they serve a crucial purpose: they tell your device which part of an IP address identifies the network and which part identifies your specific device.
A subnet mask is a 32-bit number that divides an IP address into two parts — the network portion and the host portion. It works behind the scenes every time your device sends data, determining whether traffic should stay on your local network or go out to the internet. Without subnet masks, routers wouldn't know where to send your packets — making modern networking impossible. Understanding subnet masks unlocks how IP addressing actually works, why certain devices can talk to each other while others can't, and how network admins divide large networks into manageable chunks.
This complete 2026 guide explains what a subnet mask is in plain English — no networking degree required. You'll learn how to read subnet masks, what common masks like 255.255.255.0 and 255.255.0.0 actually mean, how to calculate network and host addresses, why CIDR notation (/24, /16) matters, and how to check your own subnet mask on any device. By the end, subnetting will make complete sense.
"After two decades troubleshooting networks, running port scans, and helping businesses configure subnets properly, I've seen the same confusion repeat itself: people look at 255.255.255.0 and their eyes glaze over. The truth is, once you understand that subnet masks are just binary filters separating 'network' from 'device,' everything clicks. The decimal numbers you see — 255, 254, 128, 0 — are just human-readable translations of binary patterns that routers use to route traffic correctly.
The practical reality is this: you don't need to memorize binary to understand subnetting — you just need to grasp the basic principle. Your home network almost certainly uses 255.255.255.0 (also written as /24 in CIDR notation), which means your router assigns up to 254 devices on your local network. Corporate networks use different masks like 255.255.0.0 (/16) or 255.255.255.128 (/25) to create smaller or larger subnets depending on their needs. Understanding subnet masks isn't just for IT professionals — anyone troubleshooting Wi-Fi issues, setting up home servers, or configuring network devices benefits from knowing how subnetting actually works in 2026."
Quick Answer: What is a Subnet Mask?
A subnet mask is a 32-bit number (like 255.255.255.0) that divides an IP address into two parts: the network address (identifies which network the device is on) and the host address (identifies the specific device on that network). Routers use subnet masks to determine if traffic should stay local or be routed externally. Common home networks use 255.255.255.0 (also written as /24), which allows 254 devices. To check your subnet mask instantly, use the TrustMyIP IP checker or calculate subnet ranges with our subnet calculator tool.
1. What is a Subnet Mask? The Simple Explanation
Every device on a network needs an IP address — a unique identifier letting it send and receive data. But IP addresses alone aren't enough. Your device also needs to know: "Which part of this address identifies my network, and which part identifies me specifically?" That's where the subnet mask comes in.
A subnet mask is a 32-bit number that looks like an IP address — for example, 255.255.255.0. When your device combines its IP address with the subnet mask, it can mathematically determine two critical pieces of information: the network address (which network you're on) and your host address (your specific device on that network). This distinction matters because routers use it to decide where to send data — locally or externally.
Think of it like a mailing address. Your IP address is like "123 Main Street, Springfield" — but without knowing where "Main Street" ends and "Springfield" begins, you can't organize mail properly. The subnet mask is the dividing line that says: "Main Street is the network, 123 is the host." For a deeper understanding of how IP addresses work fundamentally, read our guide on what an IP address is and how to read IP address formats.
| Component | Example Value | Purpose |
|---|---|---|
| IP Address | 192.168.1.10 | Unique identifier for your device |
| Subnet Mask | 255.255.255.0 | Divides IP into network and host portions |
| Network Address | 192.168.1.0 | Identifies which network you're on |
| Host Address | .10 (last octet) | Identifies your specific device |
| Broadcast Address | 192.168.1.255 | Sends data to all devices on network |
2. How to Read a Subnet Mask (Decimal and Binary)
Subnet masks are displayed in two formats: decimal notation (like 255.255.255.0) and CIDR notation (like /24). Both represent the same thing — just different ways of writing it. Understanding both formats helps you read network configurations and troubleshoot connectivity issues.
In decimal notation, a subnet mask consists of four numbers (called octets) separated by dots. Each octet ranges from 0 to 255. In binary, each octet is 8 bits — so a full subnet mask is 32 bits total. The binary version shows the actual filtering pattern: consecutive 1s represent the network portion, and consecutive 0s represent the host portion.
Understanding Subnet Mask Formats
1 Common Subnet Mask: 255.255.255.0
Decimal: 255.255.255.0
Binary: 11111111.11111111.11111111.00000000
CIDR: /24 (24 bits are 1s)
Meaning: First 3 octets (24 bits) = network address. Last octet (8 bits) = host addresses. Allows 254 usable devices (2⁸ - 2 = 254).
Common use: Home networks, small offices — the most common subnet mask you'll see.
2 Larger Network: 255.255.0.0
Decimal: 255.255.0.0
Binary: 11111111.11111111.00000000.00000000
CIDR: /16 (16 bits are 1s)
Meaning: First 2 octets = network. Last 2 octets = hosts. Allows 65,534 usable devices (2¹⁶ - 2).
Common use: Medium-to-large businesses, enterprise networks needing thousands of devices on one subnet.
3 Smaller Subnet: 255.255.255.128
Decimal: 255.255.255.128
Binary: 11111111.11111111.11111111.10000000
CIDR: /25 (25 bits are 1s)
Meaning: First 3 octets plus 1 bit = network. Last 7 bits = hosts. Allows 126 usable devices (2⁷ - 2).
Common use: Dividing networks into smaller segments — security isolation, departmental subnets.
4 Why "Minus 2" for Usable Hosts?
Every subnet reserves two addresses that cannot be assigned to devices:
- Network Address (all host bits = 0): Identifies the network itself — e.g., 192.168.1.0
- Broadcast Address (all host bits = 1): Sends to all devices — e.g., 192.168.1.255
So a /24 subnet has 256 total addresses, but only 254 are usable for actual devices.
3. Common Subnet Masks and What They Mean
Different subnet masks create different-sized networks. Network administrators choose masks based on how many devices they need to support and how they want to segment traffic. Here are the most common subnet masks you'll encounter — from tiny point-to-point links to massive enterprise networks.
| Subnet Mask | CIDR | Usable Hosts | Common Use Case |
|---|---|---|---|
| 255.255.255.252 | /30 | 2 | Point-to-point router links |
| 255.255.255.248 | /29 | 6 | Very small networks — IoT sensors |
| 255.255.255.240 | /28 | 14 | Small department subnet |
| 255.255.255.224 | /27 | 30 | Office floor or team network |
| 255.255.255.192 | /26 | 62 | Mid-sized office or conference room |
| 255.255.255.128 | /25 | 126 | Security-isolated subnet |
| 255.255.255.0 | /24 | 254 | Home networks, small offices (most common) |
| 255.255.0.0 | /16 | 65,534 | Large enterprise networks |
| 255.0.0.0 | /8 | 16,777,214 | Massive networks — ISP infrastructure |
Why Home Networks Use 255.255.255.0
Your home Wi-Fi router almost certainly uses 255.255.255.0 (/24) as its default subnet mask. This configuration allows 254 devices — more than enough for most homes with smartphones, laptops, smart TVs, IoT devices, and gaming consoles. The /24 subnet provides simplicity and sufficient capacity without wasting IP space.
If you're checking your own network settings and see 192.168.1.x paired with 255.255.255.0, this means your router uses the 192.168.1.0/24 network. All devices on your network will have IPs between 192.168.1.1 and 192.168.1.254. Understanding this relationship helps you troubleshoot connectivity problems and configure port forwarding correctly. Learn more about how port forwarding works for advanced home network configuration.
4. How Subnet Masks Work: The Binary Logic
To truly understand subnet masks, you need to know what happens behind the scenes in binary. Don't worry — this isn't as complex as it sounds. The key concept: subnet masks use a mathematical operation called AND to filter IP addresses.
When your device needs to send data, it performs a bitwise AND operation between its IP address and the subnet mask. This calculation reveals the network address. If the destination IP's network address matches your network address, traffic stays local. If they don't match, your device sends the packet to the router for external routing.
Here's a real example using the most common home network configuration:
Binary AND Operation Example
Your Device IP: 192.168.1.10
Binary: 11000000.10101000.00000001.00001010
Subnet Mask: 255.255.255.0
Binary: 11111111.11111111.11111111.00000000
Result (Bitwise AND):
Binary: 11000000.10101000.00000001.00000000
Network Address: 192.168.1.0
The AND operation zeros out all host bits (where the mask is 0), leaving only the network portion. This tells your device: "Any IP starting with 192.168.1.x is on my local network. Everything else goes to the router."
5. CIDR Notation: A Simpler Way to Write Subnet Masks
CIDR (Classless Inter-Domain Routing) notation provides a shorthand way to write subnet masks. Instead of writing 255.255.255.0, you write /24 — the number after the slash indicates how many bits are "1" in the binary subnet mask. It's faster to write and easier to read once you understand the system.
CIDR replaced the old classful addressing system (Class A, B, C networks) in the 1990s, providing much more flexibility. With CIDR, network admins can create custom-sized subnets precisely matching their needs — no longer forced into rigid /8, /16, or /24 boundaries. To understand how the old class system worked and why CIDR replaced it, read our guide on IP address classes A through E.
| CIDR | Subnet Mask | Binary Representation | Hosts |
|---|---|---|---|
| /8 | 255.0.0.0 | 11111111.00000000.00000000.00000000 | 16,777,214 |
| /16 | 255.255.0.0 | 11111111.11111111.00000000.00000000 | 65,534 |
| /24 | 255.255.255.0 | 11111111.11111111.11111111.00000000 | 254 |
| /25 | 255.255.255.128 | 11111111.11111111.11111111.10000000 | 126 |
| /26 | 255.255.255.192 | 11111111.11111111.11111111.11000000 | 62 |
| /27 | 255.255.255.224 | 11111111.11111111.11111111.11100000 | 30 |
| /28 | 255.255.255.240 | 11111111.11111111.11111111.11110000 | 14 |
| /29 | 255.255.255.248 | 11111111.11111111.11111111.11111000 | 6 |
| /30 | 255.255.255.252 | 11111111.11111111.11111111.11111100 | 2 |
6. How to Find Your Subnet Mask (Every Device)
Knowing how to find your subnet mask helps troubleshoot network issues, verify configurations, and understand your local network setup. Every operating system provides simple ways to view this information.
Find Your Subnet Mask — All Platforms
1 Fastest Method: Use TrustMyIP Tools
Visit TrustMyIP.com to instantly check your IP address. For detailed subnet calculations — finding network address, broadcast address, usable host range — use our subnet calculator tool. Enter your IP and subnet mask, get instant results showing your entire network configuration.
2 Windows 10 / 11
Command Prompt: Press Win + R → type cmd → Enter → type ipconfig → look for "Subnet Mask" under your adapter.
Settings: Settings → Network & Internet → Wi-Fi or Ethernet → click your network → scroll to Properties → find Subnet mask listed.
3 macOS
Terminal: Open Terminal → type ifconfig → look for "netmask" next to your IP address (may be shown in hexadecimal like 0xffffff00 = 255.255.255.0).
System Settings: System Settings → Network → select connection → Details → TCP/IP tab → Subnet Mask shown.
4 Linux
Open Terminal → type: ip addr show or ifconfig → subnet mask shown as netmask or in CIDR notation after your IP (e.g., 192.168.1.10/24).
5 Android & iPhone
Android: Settings → About Phone → Status → shows IP and sometimes subnet mask. For full details, use network info apps.
iPhone: Settings → Wi-Fi → tap your network (i icon) → scroll to see Subnet Mask under IP configuration.
6 Router Admin Panel
Open browser → enter router IP (usually 192.168.1.1 or 192.168.0.1) → login → navigate to LAN or DHCP settings → subnet mask configuration visible and editable.
7. Subnet Mask Calculation: Finding Network and Host Addresses
Calculating network addresses, broadcast addresses, and usable host ranges from a subnet mask is a core networking skill. While tools automate this, understanding the math helps troubleshoot connectivity issues and design networks properly.
Let's walk through a practical example using a common scenario — a home network with a custom subnet configuration. Rather than manually calculating every time, use the TrustMyIP subnet calculator for instant, accurate results.
Subnet Calculation Example
Given:
IP Address: 192.168.10.45
Subnet Mask: 255.255.255.192 (/26)
Calculate:
- Network Address: Perform bitwise AND → Result: 192.168.10.0
- Broadcast Address: Set all host bits to 1 → Result: 192.168.10.63
- Usable Host Range: First to last minus reserved → 192.168.10.1 to 192.168.10.62
- Total Usable Hosts: 2⁶ - 2 = 62 devices
Interpretation:
Your device (192.168.10.45) is on the 192.168.10.0/26 subnet. Any device with an IP between 192.168.10.1 and 192.168.10.62 is on your local network. The router's gateway is likely 192.168.10.1. All other IPs require external routing.
8. Subnetting in Practice: Why Networks Are Divided
Subnetting — dividing a large network into smaller subnets — serves critical purposes beyond just address management. Modern networks use subnetting for security isolation, traffic management, organizational structure, and performance optimization.
A company might receive a /16 network (65,534 hosts) from their ISP but divide it into multiple /24 subnets (254 hosts each) — one per department. This segregation limits broadcast traffic, enables department-specific security policies, and simplifies troubleshooting. If the accounting subnet experiences issues, it doesn't impact engineering.
Benefits of Subnetting
- +Security: Isolate sensitive systems from general network
- +Performance: Reduce broadcast traffic and congestion
- +Organization: Logical grouping by department or function
- +Troubleshooting: Easier to identify and isolate network problems
- +Efficiency: Better IP address space utilization
Subnetting Challenges
- -Complexity: More subnets require careful planning and documentation
- -Wasted IPs: Each subnet reserves network and broadcast addresses
- -Routing: Inter-subnet traffic needs router configuration
- -Management: More subnets mean more DHCP scopes and firewall rules
- -Misconfiguration: Wrong subnet mask breaks connectivity silently
For IPv6 networks, subnetting works differently — every home typically receives a /64 prefix allowing 18 quintillion devices. Enterprise networks get /48 or /56 prefixes for massive subdivisions. Learn more about IPv6 addressing and subnetting in our comprehensive guide.
Conclusion: Subnet Masks Make Networks Work
A subnet mask is the invisible dividing line that tells your device — and every router — which part of an IP address identifies the network and which part identifies the host. Without subnet masks, routers wouldn't know where to send packets, and modern networking would collapse. Understanding subnet masks transforms confusing network configurations into clear, logical structures.
The key takeaways: 255.255.255.0 (/24) is the most common subnet mask for home networks, allowing 254 devices. CIDR notation (/24, /16, /30) provides shorthand that network professionals use universally. The bitwise AND operation between IP and mask reveals the network address — determining if traffic stays local or routes externally. And every subnet reserves two addresses — network and broadcast — reducing usable hosts by 2.
Use the TrustMyIP subnet calculator anytime you need instant subnet calculations — network address, broadcast address, usable range, and CIDR conversions. Check your current IP and subnet mask at TrustMyIP.com.
Keep building your networking knowledge: learn what an IP address is fundamentally, understand IP address classes and how they evolved, and explore IPv6 addressing for future-proof networks.
Calculate Your Subnet Now
Get instant subnet calculations — network address, broadcast, usable range, and CIDR conversion.