Subnet calculator (IPv4 / IPv6)
subnet_calcCalculate IPv4/IPv6 subnet details such as network, broadcast, host ranges, masks, and address types; split networks into equal subnets or allocate VLSM blocks by host counts.
Instructions
IPv4: from "192.168.1.0/26", "10.0.0.5 255.255.255.0" or a wildcard mask, get network, broadcast, first/last host, usable and total addresses, netmask, wildcard, class, address type (private, CGNAT, loopback, documentation…), integer/hex/binary forms; optionally split into N equal subnets or allocate VLSM blocks by host counts ("Sales:50, Ops:20"). /31 and /32 follow RFC 3021. IPv6: compressed (RFC 5952) and expanded forms, network, first/last address, address count, number of /64s, reverse DNS name and type. Web version: https://s3eidat.github.io/subnet-calc/
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| vlsm | No | IPv4: VLSM host requirements, e.g. "50, 20, 10" or "Sales:50, Ops:20". Largest first, each block aligned. | |
| split | No | IPv4: split the network into at least this many equal subnets (rounded up to a power of two; first 4096 listed). | |
| prefix | No | Prefix length to use when "address" has none (default /24 for IPv4, /128 for IPv6), or to override it. | |
| address | Yes | IPv4 or IPv6 address, optionally with /prefix (or an IPv4 dotted mask after a space or slash). |