Who picked 127.0.0.1 to be localhost and why? What meaning does it have?

I'm almost positive everyone on here knows the meaning of 127.0.0.1. But, why is that ALWAYS localhost? Who picked that arbitrary IP? Why was that IP picked? Why not something more simple such as 1.0.0.0? Is there some special meaning to 127.0.0.1?


Jon Postel picked 127.

Before the Internet Assigned Numbers Authority took over (RFC 3232) around the time of his death (RFC 2468), he was the "czar" of Internet address and port assignments, having essentially nominated himself for the task. (RFC 349)

Back in the early 1980s, when IPv4 as we know it was first being hashed out, existing networks were given "class A" address blocks in the 32-bit address space that would go into effect in 1983 (RFC 801). Both the initial assignments and the 127 assignment you ask about, as well as the first definitions of "class A", "class B" and "class C" IP addresses, were first published in Postel's RFC 790. (Note that "classes" were superseded by CIDR in RFC 1519, now RFC 4632.)

In RFC 790, Postel defined 127 as "reserved".

      127.rrr.rrr.rrr                 Reserved                     [JBP]

Its first formal definition appears in RFC 990, where it is defined as follows:

The class A network number 127 is assigned the "loopback" function, that is, a datagram sent by a higher level protocol to a network 127 address should loop back inside the host. No datagram "sent" to a network 127 address should ever appear on any network anywhere.

And again in RFC 1060:

(g) {127, <any>}

Internal host loopback address. Should never appear outside a host.

Thus, any address within 127.0.0.0/8 is to be considered loopback and be routed back to the local host.

The current list of special-use IPv4 addresses is RFC 6890, which obsoleted RFC 5735, which in turn obsoleted RFC 3330. RFC 5735 states:

127.0.0.0/8 - This block is assigned for use as the Internet host loopback address. A datagram sent by a higher-level protocol to an address anywhere within this block loops back inside the host. This is ordinarily implemented using only 127.0.0.1/32 for loopback. As described in [RFC1122], Section 3.2.1.3, addresses within the entire 127.0.0.0/8 block do not legitimately appear on any network anywhere.

Finally, in any IPv4 subnet, the lowest address is not usable as it represents the network route. So the first usable address in the subnet, and therefore the most commonly seen, is 127.0.0.1.


From the RFC:

127.0.0.0/8 - This block is assigned for use as the Internet host loopback address. A datagram sent by a higher level protocol to an address anywhere within this block should loop back inside the host. This is ordinarily implemented using only 127.0.0.1/32 for loopback, but no addresses within this block should ever appear on any network anywhere [RFC1700, page 5].

From wikipedia:

As with all IP addresses, defining a synonymous hostname simply makes life easier for human users — and localhost is the alias networking pioneers settled on.

Also note that 127 in binary is 01111111, the reversed and inverted value of 1 (00000001)