How to choose IP addresses and domain names for documentation

It is a good practice to not use valid domain names or already assigned IP addresses while writing documentation. I will provide you with RFC documents that are needed to reduce the likelihood of conflict and confusion.

DNS

DNS names reserved for documentation are described in RFC2606 - Reserved Top Level DNS Names and RFC6761 - Special-Use Domain Names.

Top level domain names reserved for documentation:

  • .test for testing
  • .example for examples
  • .invalid obviously for invalid domain names
  • .localhost only pointing to the loop back IP address

Second level domain names reserved for documentation:

  • example.com
  • example.net
  • example.org

IPv4

IPv4 addresses reserved for documentation are described in RFC1918 - Address Allocation for Private Internets, RFC6598 - IANA-Reserved IPv4 Prefix for Shared Address Space, RFC6890 - Special-Purpose IP Address Registries and RFC8190 - Updates to the Special-Purpose IP Address Registries and already obsolete RFC3330 - Special-Use IPv4 Addresses, RFC5735 - Special Use IPv4 Addresses.

IPv4 documentation only network block is 192.0.2.0/24.
No end party is to be assigned this address.

Do not forget about private address space:

10.0.0.0    - 10.255.255.255  (10/8 prefix)
172.16.0.0  - 172.31.255.255  (172.16/12 prefix)
192.168.0.0 - 192.168.255.255 (192.168/16 prefix)

IPv6

IPv6 addresses reserved for documentation are described in RFC3849 - IPv6 Address Prefix Reserved for Documentation.

IPv6 documentation only network block is 2001:DB8::/32.
No end party is to be assigned this address.

Milosz Galazka's Picture

About Milosz Galazka

Milosz is a Linux Foundation Certified Engineer working for a successful Polish company as a system administrator and a long time supporter of Free Software Foundation and Debian operating system. He is also open for new opportunities and challenges.

Gdansk, Poland https://sleeplessbeastie.eu