Localhost Vs HostName

The localhost resolves to 127.0.0.1 address is a special value assigned to computer network interface to enable browsing of web pages _locally_ which otherwise requires an active internet connection. Whereas Hostname resolves to a IP address defined in it’s TCP/IP configuration.

  1. 127.0.0.1 is a reserved address defined by TCP/IP protocol to route packets back to the host (thus called loopback address). Thus, no computer connected to the internet, or any other TCP/IP compliant network, can identify itself as 127.0.0.1.
  2. The Internet Engineering Task Force’s RFC 3330 defines 127.0.0.1 and 12 other special-use IPv4 addresses.
  3. A successful ping request to 127.0.0.1 will verify that a computer’s network interface card, its drivers, and the operating system’s TCP/IP implementation are all functioning correctly.

Leave a Reply

Your email address will not be published. Required fields are marked *