IPv6 calculator

This IPv6 subnet calculator converts an IPv6 address between the compressed and full forms, identifies the address type, and calculates the network range by prefix. It also generates a ULA prefix for an internal network.
Input
Enter a full or compressed address with a prefix, for example 2001:db8::1/64, or enter only the address and pick a prefix from the list.
Calculation complete.
Address forms
Network details
IPv6 has no broadcast address, so the range covers every address. A /64 is the usual size of one local network, and providers usually assign a /48 or a /56 to a site.
ULA generator

The prefix is generated in the browser and requires JavaScript.

ULA addresses are for internal networks and are not routed on the internet. The Global ID is generated at random in the browser, as RFC 4193 describes, so a clash with another internal network is unlikely.

Everything runs in your browser; nothing is sent or stored.

  • Enter an IPv6 address with a prefix, such as 2001:db8::1/64, or an address only, and choose a prefix from the "Prefix" list.
  • The "Address forms" section shows the compressed form, the full form, the address type, and the reverse DNS name.
  • The "Network details" section shows the network address, the first and last addresses, the number of addresses, and the number of /64 networks.
  • In the "ULA generator" section, click "Generate a new prefix" to get a random /48 prefix for an internal network.
  • Copy any value with the "Copy" button next to it.

Compressed and full forms

An IPv6 address is 128 bits long and is written as eight groups of four hexadecimal digits separated by colons. The compressed form drops the leading zeros in each group and replaces a run of all-zero groups with ::, which can appear only once in an address. Because the same address can be written in several ways, RFC 5952 defines one standard form: lowercase letters, compression of the longest run of two or more all-zero groups, and, when two runs are the same length, compression of the first one. The standard form makes it easier to compare addresses and to search for them in configuration files and logs.

Prefix and network size

The prefix, such as /64, states how many bits at the start of the address identify the network, and the remaining bits identify an interface in that network. Automatic address assignment with SLAAC requires a /64 network, so a local network usually gets a /64 even when only a few devices connect to it. A /48 allocation contains 65,536 /64 networks, and a /56 allocation contains 256 /64 networks, so you can divide the allocation into separate networks for each service or location.

IPv6 address types

The type of an address is set by its first bits. Public addresses (global unicast) belong to the 2000::/3 range, so they start with the digit 2 or 3. Link-local addresses in the fe80::/10 range are created automatically on every network interface and work only within the local network, so they are not suitable for DNS records. For an address that does not belong to any defined range, the "Address type" row shows "Reserved or unassigned (IANA)".

Special IPv6 addresses

  • ::1the loopback address, the IPv6 equivalent of 127.0.0.1.
  • ::the unspecified address. In the listen settings of network services, this address stands for all the IPv6 addresses of the computer.
  • fe80::1a link-local address that some networks use as the router address (default gateway).
  • fd12:3456:789a::1a unique local address (ULA) for an internal network.
  • ff02::1the multicast address of all the nodes on the local network.
  • ::ffff:192.0.2.1an IPv4-mapped address, the form in which operating systems show the address of an IPv4 connection received on an IPv6 socket.
  • 2001:db8::1an address from the 2001:db8::/32 range, which is reserved for documentation and examples and is not routed on the internet.

IPv6 calculator FAQ

What is the difference between a ULA and a link-local address?

A link-local address is created automatically on every interface, and routers do not forward it beyond the network segment that the interface is connected to. A ULA is assigned in the network settings and is routed between the internal networks of an organization, but it is not routed on the internet. The random ID in a ULA prefix reduces the chance of an address clash when two internal networks are connected, for example over a VPN.

Can I enter an IPv4 address?

No. The IPv6 calculator accepts IPv6 addresses only, and for IPv4 addresses you can use the subnet calculator. You can enter an IPv6 address that ends in dotted IPv4 notation, such as ::ffff:192.0.2.1, and the full form shows the last part as two hexadecimal groups.

Why do I see an error for an address that includes the % character?

The % character marks a zone ID, such as fe80::1%eth0. A zone ID is used with link-local addresses to choose the network interface on the computer. The zone ID is not part of the address, so remove the part that starts with % before you calculate.

Can I paste an address from a URL?

Yes. You can paste the address in square brackets, as it appears in a URL, such as [2001:db8::1]. The other parts of the URL, including the port number after the brackets, are not part of the address, so remove them before you calculate.

How do I set up reverse DNS for an IPv6 address?

A reverse DNS (PTR) record for an IPv6 address is set up under the name shown in the "Reverse DNS name (ip6.arpa)" row, in which the hexadecimal digits of the full form appear in reverse order. The record is set up by whoever manages the reverse DNS zone of the address range, usually the provider that assigned the range.

What is the maximum length of an IPv6 address I can enter?

The address field accepts up to 100 characters, including the prefix, so you can enter any IPv6 address, even in the full form.

Shopping cart

Your cart is emptyYou can start with one of our popular plans.

Site search

Accessibility

Text size
100%
Accessibility statement