CIDR Workbench treats IPv4 and IPv6 as separate calculation contracts. Both use exact integer arithmetic in this browser, but their result semantics are deliberately different. IPv4 has 32 bits; IPv6 has 128.
IPv4 boundary calculation
An IPv4 prefix /p assigns the first p bits to the network and leaves 32 − p host bits. The range contains 2^(32 − p) addresses.
- Convert the four decimal octets to one unsigned 32-bit value.
- Create a mask with the leading prefix bits set to one.
- Apply the mask to get the network address.
- Set every host bit to one to get the upper or broadcast field.
For 192.168.1.42/24, 24 network bits leave eight host bits. The block contains 256 addresses from 192.168.1.0 to 192.168.1.255. Under traditional subnet semantics, hosts run from .1 through .254.
IPv6 boundary calculation
An IPv6 prefix /p keeps the first p bits and leaves 128 − p remaining bits, for exactly 2^(128 − p) addresses. The calculator clears the remaining bits for the network and first boundary, then sets them to one for the last boundary. All arithmetic uses BigInt, so even ::/0 is calculated exactly.
Every whole-number prefix length from /0 through /128 is valid. IPv6 routing is classless: split advances the prefix by one bit, and joining aligned equal-length siblings removes one bit. Common boundaries such as /48, /56, /60, and /64 are useful operational conventions, not a whitelist of valid lengths.
IPv6 has no broadcast address. The tool therefore reports first and last mathematical boundaries, not a broadcast field, wildcard mask or IPv4-style usable-host count. Whether an address may be assigned depends on its type, link and operational context.
IPv6 text parsing and canonical output
Input accepts all eight hextets, one :: token that compresses one or more zero hextets, and an RFC 4291 dotted IPv4 value in the final 32 bits. Scoped zone identifiers are rejected because they identify an interface in a local system context rather than part of the 128-bit address.
Output follows RFC 5952: hexadecimal letters are lowercase, leading zeroes are removed, the longest run of two or more zero hextets is compressed, and the first run wins when lengths tie. IPv4-mapped addresses use the recommended mixed notation. A fully expanded lowercase form remains beside the canonical result for learning and verification.
IPv6 boundary examples
::/0spans all2^128values. It is a routing boundary, not an ordinary LAN.- A
/48contains 65,536 complete/64networks. A/56, which is a common residential or small-office delegation rather than a universal requirement, contains 256. A/60contains 16. 2001:db8::1/64becomes2001:db8::/64. A/64is a common subnet boundary, but that does not make every prefix an ordinary LAN or prescribe an assignment mechanism.- RFC 6164 permits a
/127on a point-to-point inter-router link. The two values shown are range boundaries, not an IPv4 network/broadcast pair. - A
/128identifies one address, so its first and last values coincide.
The 128-bit visualisation labels the prefix and remaining/interface space with text and bit counts. Pattern, border and colour reinforce that boundary, but the meaning never depends on colour alone.
Visual subnetting and sibling joining
The IPv4 and IPv6 planners start at the calculated network boundary, so an input such as 192.168.1.42/24 has 192.168.1.0/24 as its parent allocation, while 2001:db8::1234/64 has 2001:db8::/64. Split replaces one current subnet with its two exact halves. Each child has the next prefix length and together they cover exactly the same addresses as the subnet they replace.
Join is the inverse operation. It is valid only for two adjacent allocations with the same prefix when they are the correctly aligned left and right children of one parent. Equal-sized neighbours that are not siblings cannot be joined. These rules keep the current allocations ordered, non-overlapping, gap-free, and equal in total range to the original parent.
The vertically scrollable tree shows every split from the parent to the current subnets, ordered from the network address to the upper boundary. Every current CIDR is an interactive row. Choose Split or Join, then activate the relevant row with a pointer, touch or keyboard; either member of a valid sibling pair can trigger its join. One detail panel exposes family-appropriate values for the resulting selected subnet. IPv6 plans report mathematical first and last boundaries, the number of complete /64 networks when applicable, readable approximate address counts, exact counts, and bit lengths without IPv4-only fields. Prefixes longer than /64 contain no complete /64. Copy Markdown and Copy JSON preserve exact values and export the complete ordered plan to the browser clipboard without sending it to a server.
IPv4 point-to-point and host routes
RFC 3021 permits both addresses in a /31 on a point-to-point link; neither acts as broadcast. A /32 identifies one host route. In a plan, a /31 can be divided into two /32 routes, and valid siblings can be joined again.
Limits
- IPv4 accepts dotted decimal without ambiguous leading zeroes. IPv6 does not accept zone identifiers, ports, brackets or trailing text.
- The calculator does not validate whether an address is routed, assigned, special-purpose or suitable for a device. It does not perform DNS or ownership lookups, SLAAC or DHCPv6 planning, or automatic assignment.
- Each IPv4 or IPv6 plan is limited to 256 current subnets to bound browser memory and rendering. Split is unavailable at the cap; Join, Restore parent and Reset remain available as appropriate. A
/32is terminal in IPv4 and a/128is terminal in IPv6. - VLSM by requested host count, cloud-provider reservations, arbitrary aggregation, overlap analysis, saved plans and file download are not included.
- This planner models an allocation on this page only. It does not reserve, route or configure addresses, and it does not change a real network.
Sources
- RFC 7608 — IPv6 Prefix Length Recommendation for Forwarding (checked 12 August 2026)
- RFC 4291 — IPv6 Addressing Architecture (checked 12 August 2026)
- RFC 5952 — IPv6 Address Text Representation (checked 12 August 2026)
- RFC 6177 — IPv6 Address Assignment to End Sites (checked 12 August 2026)
- RFC 4862 — IPv6 Stateless Address Autoconfiguration (checked 12 August 2026)
- RFC 6164 — 127-Bit IPv6 Prefixes on Inter-Router Links (checked 12 August 2026)
- RIPE — Create an IPv6 Addressing Plan (checked 12 August 2026)
- RFC 4632 — Classless Inter-domain Routing
- RFC 3021 — 31-Bit Prefixes on IPv4 Point-to-Point Links