How to Locate and Edit Hosts File on a Mac Using Terminal
The hosts file in an operating system is used to convert domain names to IP addresses. Users can enter their hosts files and go to the IP addresses they define themselves, instead of replies from the DNS server.