ShowIP.net
Menu

Network tool

CIDR calculator

Calculate the address range and size of an IPv4 or IPv6 CIDR network, for example when checking a firewall rule or a hosting provider’s allocation.

Input
2001:db8::/32
Canonical network
2001:db8::/32
IP version
IPv6
Prefix length
32
Network address
2001:db8::
First address
2001:db8::
Last address
2001:db8:ffff:ffff:ffff:ffff:ffff:ffff
Total addresses
79228162514264337593543950336
Netmask
Not used for IPv6
Broadcast
Not used for IPv6
Usable hosts
N/A

Reference

Network range and address counts

Canonical network
The normalized CIDR block after host bits are cleared, such as 8.8.8.0/24.
First and last address
The full inclusive range covered by the prefix.
Total addresses
The number of IPv4 or IPv6 addresses in the block.
Netmask and broadcast
IPv4 fields used in traditional network tooling; usable host counts are also shown for IPv4. IPv6 uses prefix lengths and has no broadcast address, so its netmask and broadcast fields are marked as not used.

Advertisement

Examples

Host-prefix and IPv6 examples

Host-prefix IPv4

8.8.8.8/24 Normalizes to 8.8.8.0/24 and shows the full 256-address range. Calculate 8.8.8.8/24

IPv6 network

2001:db8::/32 Shows the first and last address in an IPv6 documentation prefix. Calculate 2001:db8::/32

Boundaries

Limits

This calculator accepts one IPv4 or IPv6 CIDR network at a time. It does not check whether a public block is assigned to a specific organization; use the IP lookup and ASN guide for that network context. The CIDR notation guide explains prefix lengths and host bits.

IP and CIDR libraries

Build the same kind of checks into your code using these documented libraries.

Python: ipaddress

Standard-library IPv4 and IPv6 parsing, networks and membership checks.

Go: net/netip

Standard-library address and prefix types with Contains and Overlaps methods.

ShowIP endpoint documentation

Next steps

Advertisement