CalculatorFly.com Logo - Free Online Calculators

CalculatorFly

IPv4 Subnet Calculator

Calculate subnet details like network address, broadcast address, host range, and more from an IPv4 address and subnet mask.

IPv4 Subnet Calculator
Enter an IP address and select a subnet mask to calculate network details.

Understanding IPv4 Subnetting

An IPv4 address is a 32-bit number that uniquely identifies a device on a network. Subnetting is the process of dividing a large network into smaller, more manageable sub-networks, or "subnets." This is crucial for network organization, security, and efficient use of IP addresses. Our IPv4 Subnet Calculator is a powerful tool for network administrators, students, and IT professionals to quickly determine the properties of a given subnet.


🖥️ How to Use the Calculator

To analyze an IPv4 subnet:

  1. Enter IP Address: Input a valid IPv4 address (e.g., 192.168.1.10).
  2. Select Subnet Mask: Use the dropdown to select the subnet mask in either CIDR notation (e.g., /24) or dotted-decimal format (e.g., 255.255.255.0).
  3. Calculate: Click the "Calculate Subnet" button.

The calculator will display a comprehensive list of details about the subnet, including its binary representations, usable host range, and other technical data.


Key Subnetting Concepts

The calculator uses bitwise logical operations to determine the subnet's properties:

  • Network Address: The first address in a subnet, which identifies the subnet itself. It's calculated by performing a bitwise AND operation between the IP address and the subnet mask. Individual devices cannot be assigned this address.
  • Broadcast Address: The last address in a subnet. Packets sent to this address are delivered to all hosts within that subnet. It's found by performing a bitwise OR operation between the network address and the inverted subnet mask (wildcard mask). This address is also reserved.
  • Usable Host Range: The range of IP addresses between the network address and the broadcast address that can be assigned to individual devices. It is calculated as Network Address + 1 to Broadcast Address - 1.
  • Total Hosts: The total number of possible addresses in the subnet, including the reserved network and broadcast addresses. Calculated as 2(32 - CIDR).
  • Wildcard Mask: The inverse of the subnet mask, often used in router access control lists (ACLs).

IPv4 Subnet Reference Table

Below is a table providing typical subnets for IPv4, including their prefix size, network mask, and the number of usable hosts per subnet. The traditional classful network boundaries (A, B, C) are noted for historical context.

Prefix SizeNetwork MaskUsable Hosts per Subnet
/1128.0.0.02,147,483,646
/2192.0.0.01,073,741,822
/3224.0.0.0536,870,910
/4240.0.0.0268,435,454
/5248.0.0.0134,217,726
/6252.0.0.067,108,862
/7254.0.0.033,554,430
Class A
/8255.0.0.016,777,214
/9255.128.0.08,388,606
/10255.192.0.04,194,302
/11255.224.0.02,097,150
/12255.240.0.01,048,574
/13255.248.0.0524,286
/14255.252.0.0262,142
/15255.254.0.0131,070
Class B
/16255.255.0.065,534
/17255.255.128.032,766
/18255.255.192.016,382
/19255.255.224.08,190
/20255.255.240.04,094
/21255.255.248.02,046
/22255.255.252.01,022
/23255.255.254.0510
Class C
/24255.255.255.0254
/25255.255.255.128126
/26255.255.255.19262
/27255.255.255.22430
/28255.255.255.24014
/29255.255.255.2486
/30255.255.255.2522
/31255.255.255.2540
/32255.255.255.2550

💡 Frequently Asked Questions (FAQ)

What is CIDR?
CIDR stands for Classless Inter-Domain Routing. It's a method for allocating IP addresses and routing IP packets. The CIDR notation (e.g., /24) is a compact way to represent a subnet mask by specifying the number of leading '1' bits in the mask.
What are IP address classes (A, B, C)?
This is an older system of classifying IP addresses called "classful networking." While largely replaced by CIDR, the classes are still referred to for context. Class A networks had a default mask of /8, Class B had /16, and Class C had /24.
Why can't I use the first and last IP addresses in a subnet?
The first address is the Network Address, which identifies the entire subnet and is used in routing tables. The last address is the Broadcast Address, used to send messages to all devices on the subnet simultaneously. Because they have special functions, they cannot be assigned to individual hosts.

Related Keywords

ipv4 subnet
subnet calculator
ip address
network address
broadcast address
subnet mask
cidr
networking tools