IPv4 Subnet Calculator
subnet_calcCompute IPv4 subnet details from CIDR notation locally: get network and broadcast addresses, usable host range, total hosts, subnet mask, and wildcard mask. Handles /31 and /32 per RFC 3021.
Instructions
Compute IPv4 subnet details from CIDR notation entirely locally — no network call: network and broadcast addresses, usable host range, total usable hosts, subnet mask, and wildcard mask. /31 and /32 are handled per RFC 3021 (point-to-point / single host). Use this for IPv4 address planning. It does not query DNS or contact any host, so it is purely computational. Requires no API key and is NOT rate-limited (computed in-process). Returns the calculated fields as text.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cidr | Yes | IPv4 address with a CIDR prefix length 0-32 (e.g., '192.168.1.0/24'). IPv4 only; host bits may be any address inside the block. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| prefix | Yes | CIDR prefix length | |
| network | Yes | Network address | |
| lastHost | Yes | Last usable host | |
| broadcast | Yes | Broadcast address | |
| firstHost | Yes | First usable host | |
| reportUrl | Yes | Human-facing interactive report on dechonet.com | |
| subnetMask | Yes | Dotted-decimal subnet mask | |
| totalHosts | Yes | Usable host count | |
| wildcardMask | Yes | Wildcard (inverse) mask |