ITNuvoAkademiya
Academy homePackagesPlaylistsToolsSubnet calculatorSearchGlossary
CiscoCCNA · CCNA: networking fundamentals1. Introduction2. Network Fundamentals3. Network Access4. IP Connectivity5. IP Services6. IPv67. Security Fundamentals8. AutomationCCNP: Enterprise networks · coming soon
LinuxLinux: system administrator üçün · Linux for system administrators1. Getting to know Linux2. Working with text3. Users and permissions4. Processes and packages5. Inside the system6. Monitoring and logs7. NetworkingRed Hat Enterprise Linux · Red Hat Enterprise Linux: from beginner to advanced1. Getting started2. Packages3. Users and permissions4. SELinux5. Services6. Storage7. Networking8. Building services9. Boot and recovery10. DevOps11. Security and monitoring
FortinetFortiGate Administrator · FortiGate Administrator: from first login to ZTNA1. Getting to know FortiGate2. Routing, policy and NAT3. Security profiles4. Users and logs5. Resilience, SD-WAN and automation6. VDOM7. VPN and ZTNA8. Proxy9. DMZ
MonitoringZabbix · Zabbix: from installation to alerts1. Introduction2. Installation and the database3. Basics: groups, templates, users4. Connecting devices5. Alerts, Grafana and the API
VirtualizationProxmox VE · coming soonVMware ESXi · coming soon
My account / Sign in
AZENRU
← itnuvo.com

Introduction to IPv6: why IPv6, the header, address format and shortening rules

Lesson 6.19 minBeginnerNovember 16, 2026
Open

This lesson is open to everyone. The other lessons open with a package: sign in or sign up, then choose a package.

Key points

  • IPv4: 32 bits = 4,294,967,296 addresses. IPv6: 128 bits: about 3.4 × 10³⁸ addresses. VLSM and NAT/PAT extended IPv4's life, but they were not enough.
  • IPv4 and IPv6 are not compatible: OSPFv2 → OSPFv3, ICMP → ICMPv6, ARP → NDP. Running both at the same time is called dual stack.
  • The IPv6 header is simpler: the checksum and fragmentation fields were removed, TTL → Hop Limit, Protocol → Next Header, and Flow Label is new.
  • Format: 8 groups × 4 hex characters, separated by colons (:). Each hex character is 4 bits (0–9, A=10 ... F=15).
  • Shortening: (1) drop the leading zeros in each group, 0000 → 0; (2) replace a run of zero groups with :: only once. Example: 2001:0DB8:0000:00A1:0000:0000:0000:0B07 → 2001:DB8:0:A1::B07.

Why IPv6?

For as long as the Internet has existed, IPv4 has been used for addressing and routing. The problem with IPv4 is that we are running out of addresses.

IPv4 has 32 bits, which means 2³² = 4,294,967,296 IP addresses. Remember the class A, B and C system from earlier in the course: in the early days of the Internet, companies received a whole class A, B or C network.

ClassNumber of addresses
C256
B65,536
A16,777,216

Large companies got one or more class A networks, but did they really need 16 million addresses? Many addresses were wasted.

Then we started using VLSM (Variable Length Subnet Mask): we could use any subnet mask and create smaller subnets. With NAT and PAT we also started placing many private addresses behind a single public address.

Even so, the Internet grew in a way nobody expected. Despite tricks like VLSM and NAT/PAT, more addresses were needed, and IPv6 was born.

What happened to IPv5? IP version 5 was used for an experimental project called the "Internet Stream Protocol" (RFC 1819).

IPv6 addresses are 128 bits long. Every extra bit doubles the number of addresses. This is 2¹²⁸:

340,282,366,920,938,463,463,374,607,431,768,211,456

That is about 3.4 × 10³⁸ addresses: enough for everyone and every device. IPv6 addresses are written in hexadecimal.

Exam note: IPv6 is in the Network Fundamentals section of the CCNA 200-301 exam: you need to configure and verify IPv6 addressing and prefixes and describe the IPv6 address types.

IPv4 and IPv6 are not compatible

IPv4 and IPv6 are not compatible with each other, so many protocols have been updated or replaced for IPv6:

IPv4IPv6
OSPF version 2OSPFv3
ICMPICMPv6
ARPNDP (Neighbor Discovery Protocol)

The future is a migration from IPv4 to IPv6. This means that for a while both protocols will run on the network. Perhaps one day, when the whole Internet is configured for IPv6, we can switch IPv4 off completely. Running IPv4 and IPv6 at the same time is called dual stack.

The IPv6 header

IPv4 headerVersionIHLToSTotal LengthIdentificationFlagsFrag. OffsetTTLProtocolHeader ChecksumSource AddressDestination AddressOptions + PaddingIPv6 headerVersionTraffic ClassFlow LabelPayload LengthNext HeaderHop LimitSource Address (128 bit)Destination Address (128 bit)in bothremoved in IPv6renamed/movednew in IPv6
Figure 1 · The IPv6 header is simpler: some IPv4 fields were removed, some renamed, and Flow Label is new

An IPv6 packet header also contains the source and destination addresses, but compared to IPv4 it has become much simpler:

ChangeFields
RemovedIHL, Identification, Flags, Fragment Offset, Header Checksum, Options/Padding
RenamedToS → Traffic Class, Total Length → Payload Length, TTL → Hop Limit, Protocol → Next Header
NewFlow Label
KeptVersion, Source Address, Destination Address (now 128 bits)

Instead of putting every field in the header up front, IPv6 uses the Next Header field, which points to additional (optional) headers. Because the header is simpler, routers have less work to do.

IPv6 routing

What changes in routing? The routing options for IPv6:

MethodNote
Static routingJust like IPv4, nothing new
RIPngThe updated version of RIP (RIP next generation)
OSPFv3OSPF for IPv4 is version 2; for IPv6 it is version 3. It is a separate protocol that only runs IPv6
EIGRPSupports IPv6
MP-BGPMulti-Protocol BGP: the protocol that glues the Internet together can also route IPv6 (not a CCNA topic)

Keep in mind: OSPF and EIGRP support IPv6, but these are separate processes. In a network with both IPv4 and IPv6, you run one routing protocol process for IPv4 and another for IPv6.

The hexadecimal system

An IPv6 address is hexadecimal. If you are not sure how hexadecimal works, look at this table:

HexBinaryHexBinary
0000081000
1000191001
20010A1010
30011B1011
40100C1100
50101D1101
60110E1110
70111F1111

In hexadecimal we count from 0 to F, just like 0 to 15 in decimal: A = 10, B = 11, C = 12, D = 13, E = 14, F = 15. Each hex character is exactly 4 bits.

The IPv6 address format

20010DB8000000A10000000000000B0716 bit16 bit16 bit16 bit16 bit16 bit16 bit16 bit8 groups × 4 hex characters × 4 bits = 128 bits
Figure 2 · An IPv6 address: eight groups separated by colons, four hexadecimal characters each

An example address:

2001:0DB8:0000:00A1:0000:0000:0000:0B07

  • It is hexadecimal and much longer than an IPv4 address.
  • There are eight groups, each with four hex characters (16 bits).
  • 128 bits = 32 hex characters.

In these lessons we use the 2001:DB8::/32 range for examples. This range is reserved for documentation and examples (RFC 3849) and is never assigned on a real network.

Shortening rules

Hexadecimal makes the address shorter, but typing an IPv6 address is still a lot of work. Imagine calling a friend and saying: "please ping 2001:0DB8:0000:00A1:0000:0000:0000:0B07". That's why IPv6 addresses can be shortened.

Full2001:0DB8:0000:00A1:0000:0000:0000:0B071. Leading zeros2001:DB8:0:A1:0:0:0:B072. Run of zero groups → ::2001:DB8:0:A1::B07
Figure 3 · Shortening: first drop the leading zeros in each group, then replace one run of zero groups with :: (only once)

Rule 1: drop the leading zeros in each group.

text
Full:    2001:0DB8:0000:00A1:0000:0000:0000:0B07
Short:   2001:DB8:0:A1:0:0:0:B07
  • 0DB8 → DB8, 00A1 → A1, 0B07 → B07: the zeros at the start of a group are dropped.
  • 0000 → 0: a group of four zeros keeps a single zero.
  • Zeros at the end are not dropped: A100 is not A1!

Another example:

text
Full:    2001:0DB8:0001:0002:0003:0004:0005:0006
Short:   2001:DB8:1:2:3:4:5:6

Rule 2: replace a run of zero groups with :: once.

text
Short:   2001:DB8:0:A1:0:0:0:B07
Shorter: 2001:DB8:0:A1::B07

The three consecutive zero groups (0:0:0) were replaced by ::.

:: may only be used once. This address has two separate places with zeros (the 3rd group and groups 5–7). If we replaced both with ::, we would get 2001:DB8::A1::B07. That is wrong: a device could not tell how many groups each :: replaces, and could not expand the address back to 128 bits. So :: goes on the longest run of zeros.

RuleExample
Leading zeros are dropped0DB8 → DB8, 0000 → 0
A run of zero groups → ::0:0:0 → ::
:: only once2001:DB8::A1::B07 is wrong

Check yourself

5 questions · answers are shown instantly · 3 correct answers complete the lesson

1How many bits is an IPv6 address?

IPv6 is 128 bits, IPv4 is 32 bits.

2Which protocol does the job of IPv4's ARP in IPv6?

In IPv6, ARP was replaced by NDP.

3Which IPv6 header field corresponds to IPv4's TTL?

TTL → Hop Limit, Protocol → Next Header, ToS → Traffic Class.

4What is the correct short form of 2001:0DB8:0000:00A1:0000:0000:0000:0B07?

:: is used only once; zeros at the end of a group are not dropped.

5Why can :: be used only once?

To expand the address back to 128 bits, the position of the zero groups must be unambiguous.
Was this lesson useful?

Comments

Sign in to comment.