MacOS® and Linux®
To modify your /etc/hosts file if your workstation runs MacOS or a Linux distribution, perform the following steps:
- On your workstation, open the /etc/hosts file with your preferred text editor.
-
Add the server's IP address and domain name under the last entry in the file, for example:
1234127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4::1 localhost localhost.localdomain localhost6 localhost6.localdomain6192.168.0.20 example.com1.2.3.4 username.example.comNote:
In this example, 1.2.3.4 represents the server's IP address, and username.example.com represents the domain name.
-
Save your changes.
-
Reload your browser for the changes to take effect.
Microsoft Windows
To modify the /etc/hosts file on a Windows workstation, perform the following steps:
- Open the Start menu.
- If you run Windows 8 or Windows 10, type Win+X on the keyboard or click the Windows icon in the lower-left corner of your desktop interface.
- If you run Windows 7 or Windows Vista®, click Start.
- Enter Notepad in the search text box.
- Right-click Notepad and select Run as Administrator.
-
In Notepad, open the following file:
C:\Windows\System32\Drivers\etc\hosts -
Add the destination server's IP address and domain name under the latest entry in the file, for example:
1234127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4::1 localhost localhost.localdomain localhost6 localhost6.localdomain6192.168.0.20 example.com1.2.3.4 username.example.comNote:
In this example, 1.2.3.4 represents the destination server's IP address, and username.example.com represents the domain name.
- Save your changes.
- Reload your browser for the changes to take effect.