![]() 127.0.0.1 vs localhostīoth 127.0.0.1 and localhost are used to refer to the local machine or the computer you are currently working on. In this article, we will explore the differences between these IP addresses and when to use each of them. You may also be familiar with “0.0.0.0” and wonder how it compares to the former two. We often use this function without even realizing it : if an application or service opens a web page for managing settings without accessing the Internet, we are almost certainly using localhost to take advantage of the interface, unless we use web apps with offline functionality .Īs a developer, you may have come across the terms “127.0.0.1” and “localhost” when setting up a local server or working with networking protocols. In the end we can say that 127.0.0.1 or localhost is a sort of “mirror” in which the PC reflects itself: if the PC “speaks” the mirror reflects its “speeches”, so as to be able to access certain functions related to the sites web or local web servers (without internet access). ![]() Obviously all devices that connect to a network will have their own 127.0.0.1, which can be used exclusively for local web servers or to test some network features. To conclude, it is interesting to know that 127.0.0.1 is the internal address on devices that use TCP / IP version 4 (IPv4) , ie the most common. In recent years it has also spread to TCP / IP version 6 : on this type of networks the local address corresponds to the number 0: 0: 0: 0: 0: 0: 0: 1. Class 127 has a particular function: all the IPs starting with 127 have a “loopback” function that makes the sent packets go back to the sender, without ever leaving the sending device. Within the 127 subnet, therefore, the IP address 127.0.0.1 is the first that can be assigned (127.0.0.0 cannot be used) and, since the PC in use is the only one that can “bounce its own packages “, is also the only available address of this type. The address 127.0.0.1 always corresponds to our terminal and you can never identify another computer or device on the network, also seen how a LAN network works. By carefully analyzing the numbers of the IP address we can see that 127 is the last number of a network with a Subnet Mask of value 255.0.0.0 . Does 127.0.0.1 always match our computer? ![]() The best users can also modify the hosts file and point a website or an IP address of a web page to 127.0.0.1: in this way, since the requested server cannot be present on our terminal, the page will not be loaded on browsers and it will not be possible to browse that page. The address 127.0.0.1 is associated with the word localhost because this is how Windows defines it in the hosts file , a special file that we can find in the C: Windows System32 drivers etc folder . The 127.0.0.1 address is a special IP address that identifies our own computer within the network it is also referred to as localhost . Using this address, our computer, within a traditional LAN network, can contact itself through a program, a network client or a browser.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |