Reverse DNS (rDNS) is the process of resolving an IP address back to a hostname using DNS PTR (pointer) records. While conceptually similar to IPv4 reverse DNS, IPv6 reverse DNS has unique characteristics due to the vastly larger address space and different notation requirements. This guide covers everything you need to know about configuring IPv6 reverse DNS, from understanding the ip6.arpa domain structure to practical implementation in various environments.
Before configuring reverse DNS, you should verify your IPv6 connectivity is working properly. Tools like test-ipv6.run can help you confirm your IPv6 setup is functional before adding reverse DNS records.
IPv6 reverse DNS uses the special domain ip6.arpa (analogous to in-addr.arpa for IPv4). When performing a reverse lookup, an IPv6 address is converted into a special format and queried under this domain to retrieve the corresponding PTR record.
The key difference between IPv4 and IPv6 reverse DNS is the "nibble format" used for IPv6. A nibble represents 4 bits (one hexadecimal digit) of the address. IPv6 reverse DNS zones must be created on nibble boundaries, meaning zone delegations occur at prefix lengths divisible by 4 (e.g., /124, /120, /116, /112, /64, /48, /32).
The conversion process involves several steps:
Example:
IPv6 Address: 2001:db8::567:89ab
Expanded: 2001:0db8:0000:0000:0000:0000:0567:89ab
Remove colons: 20010db8000000000000000005678ab
Reverse: ba9876500000000000000008bd01002
Add dots: b.a.9.8.7.6.5.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.8.b.d.0.1.0.0.2
Final format: b.a.9.8.7.6.5.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.8.b.d.0.1.0.0.2.ip6.arpa.
This unwieldy 72-character domain name is what DNS servers query to retrieve the PTR record for the IPv6 address.
BIND (Berkeley Internet Name Domain) is the most widely used DNS server software. Here's how to configure IPv6 reverse DNS in BIND 9.
For a /48 IPv6 allocation (e.g., 2001:db8::/48), add the following to your named.conf:
zone "8.b.d.0.1.0.0.2.ip6.arpa" {
type master;
file "/etc/bind/db.2001:db8";
allow-update { none; };
};
For a /64 prefix (2001:db8:1234:5678::/64):
zone "8.7.6.5.4.3.2.1.8.b.d.0.1.0.0.2.ip6.arpa" {
type master;
file "/etc/bind/db.2001:db8:1234:5678";
allow-update { none; };
};
Create the zone file (/etc/bind/db.2001:db8:1234:5678) with the following format:
$TTL 86400
@ IN SOA ns1.example.com. hostmaster.example.com. (
2025102001 ; Serial (YYYYMMDDNN)
3600 ; Refresh
1800 ; Retry
604800 ; Expire
86400 ) ; Minimum TTL
; Name servers
IN NS ns1.example.com.
IN NS ns2.example.com.
; PTR records for specific hosts
; 2001:db8:1234:5678::1
1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 IN PTR server1.example.com.
; 2001:db8:1234:5678::10
0.1.0.0.0.0.0.0.0.0.0.0.0.0.0.0 IN PTR server2.example.com.
; 2001:db8:1234:5678::100
0.0.1.0.0.0.0.0.0.0.0.0.0.0.0.0 IN PTR server3.example.com.
; 2001:db8:1234:5678::abcd:ef01
1.0.f.e.d.c.b.a.0.0.0.0.0.0.0.0 IN PTR webserver.example.com.
To reduce repetition, use the $ORIGIN directive:
$ORIGIN 8.7.6.5.4.3.2.1.8.b.d.0.1.0.0.2.ip6.arpa.
$TTL 86400
@ IN SOA ns1.example.com. hostmaster.example.com. (
2025102001 3600 1800 604800 86400 )
IN NS ns1.example.com.
IN NS ns2.example.com.
1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 IN PTR server1.example.com.
0.1.0.0.0.0.0.0.0.0.0.0.0.0.0.0 IN PTR server2.example.com.
PowerDNS can manage IPv6 PTR records through its backend database or zone files. For zone files:
$ORIGIN 8.7.6.5.4.3.2.1.8.b.d.0.1.0.0.2.ip6.arpa.
@ IN SOA ns1.example.com. admin.example.com. (
2025102001 10800 3600 604800 3600 )
IN NS ns1.example.com.
1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 IN PTR host.example.com.
In nsd.conf:
zone:
name: "8.b.d.0.1.0.0.2.ip6.arpa"
zonefile: "/etc/nsd/zones/2001-db8-reverse.zone"
The zone file format is similar to BIND.
For smaller deployments, dnsmasq can handle reverse DNS with simple configuration:
host-record=server1.example.com,2001:db8:1234:5678::1
ptr-record=1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.8.7.6.5.4.3.2.1.8.b.d.0.1.0.0.2.ip6.arpa,server1.example.com
Or use the automatic reverse DNS feature:
# Forward and reverse will be automatically created
host-record=server1.example.com,2001:db8:1234:5678::1
Most organizations do not directly control their IPv6 reverse DNS zones. The Regional Internet Registry (RIR) or Internet Service Provider (ISP) that allocated your IPv6 address space maintains authority over the reverse DNS delegation.
IPv6 reverse DNS can be delegated at any nibble boundary:
If your prefix length is not on a nibble boundary (e.g., /52 or /60), you must use the next larger nibble boundary (/48 or /56 respectively) for delegation.
To get reverse DNS delegated to your own nameservers:
IPv6 Prefix: 2001:db8:1234::/48
Nameservers:
- ns1.example.com (192.0.2.10, 2001:db8:1234::10)
- ns2.example.com (192.0.2.11, 2001:db8:1234::11)
Requested zone: 4.3.2.1.8.b.d.0.1.0.0.2.ip6.arpa
Many ISPs provide web interfaces or APIs to configure reverse DNS without requiring full zone delegation:
Web Control Panel Method:
API Method (varies by provider):
# Example using a hypothetical API
curl -X POST https://api.isp.example/v1/rdns \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{
"ipv6": "2001:db8:1234:5678::1",
"hostname": "server1.example.com"
}'
AWS (Amazon Web Services):
Google Cloud Platform:
DigitalOcean:
Linode:
For dedicated servers or colocation:
Proper reverse DNS is critical for email server deliverability, especially as mail providers increasingly support IPv6:
PTR Record:
; 2001:db8:1234::25
5.2.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.4.3.2.1.8.b.d.0.1.0.0.2.ip6.arpa.
IN PTR mail.example.com.
Forward Record (AAAA):
mail.example.com. IN AAAA 2001:db8:1234::25
SPF Record:
example.com. IN TXT "v=spf1 ip4:192.0.2.0/24 ip6:2001:db8:1234::/48 -all"
Major email providers check reverse DNS:
The most reliable verification method uses the dig command with the -x flag:
# Basic reverse lookup
dig -x 2001:db8:1234:5678::1
# Query specific nameserver
dig -x 2001:db8:1234:5678::1 @8.8.8.8
# Short output
dig -x 2001:db8:1234:5678::1 +short
Expected output:
server1.example.com.
nslookup 2001:db8:1234:5678::1
Expected output:
1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.8.7.6.5.4.3.2.1.8.b.d.0.1.0.0.2.ip6.arpa
name = server1.example.com.
host 2001:db8:1234:5678::1
Expected output:
1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.8.7.6.5.4.3.2.1.8.b.d.0.1.0.0.2.ip6.arpa domain name pointer server1.example.com.
To ensure FCrDNS is properly configured:
# Step 1: Get the hostname from reverse lookup
HOSTNAME=$(dig -x 2001:db8:1234:5678::1 +short)
# Step 2: Lookup the IPv6 address for that hostname
dig $HOSTNAME AAAA +short
# Should return: 2001:db8:1234:5678::1
Several online tools can verify your IPv6 reverse DNS configuration:
If reverse DNS is not working:
Check zone delegation:
dig NS 8.b.d.0.1.0.0.2.ip6.arpa
Query authoritative nameserver directly:
dig -x 2001:db8:1234:5678::1 @ns1.example.com
Verify zone serial number updated:
dig SOA 8.b.d.0.1.0.0.2.ip6.arpa
Check for DNSSEC issues:
dig -x 2001:db8:1234:5678::1 +dnssec
Test from multiple resolvers:
dig -x 2001:db8:1234:5678::1 @8.8.8.8 # Google
dig -x 2001:db8:1234:5678::1 @1.1.1.1 # Cloudflare
dig -x 2001:db8:1234:5678::1 @208.67.222.222 # OpenDNS
example.com.)The enormous size of IPv6 address space creates unique challenges:
Configuring IPv6 reverse DNS requires understanding the nibble format, proper zone delegation, and coordination with your ISP or hosting provider. While the concepts are similar to IPv4, the scale and complexity of IPv6 addressing demand more careful planning and often automation.
For most users, the simplest path is using ISP-provided reverse DNS management tools or requesting delegation to your own nameservers for larger deployments. Email server operators should prioritize forward-confirmed reverse DNS to ensure deliverability.
Before configuring reverse DNS, always verify your IPv6 connectivity is working correctly using tools like test-ipv6.run. Proper reverse DNS configuration, combined with good IPv6 connectivity, ensures your services are accessible and trusted across the modern internet.