Instructions
Jump to: B: Windows 11
A: macOS
- Open the Terminal app.
- In the Terminal window, type sudo nano /etc/hosts and press the return key on your keyboard:
- Type the password of the current administrator account on your Mac. Then, press return.
NOTE: The Terminal window will not display any indication that you are typing your password. Simply type your password as normal and press return. - Make any necessary changes, and then press control+O on your keyboard to save the file.
TIP: You can navigate up, down, left, and right by using the arrow keys on your Mac's keyboard.
NOTE: Entries that begin with the pound sign (#) are for comments or examples. They act as if they are not there. For entries to work, do not use the pound sign (#). - At the bottom of the Terminal window, Terminal will ask you to confirm the file name to which to save the changes. Simply press return without making any changes to the default file name (/etc/hosts).
- At the bottom of the Terminal, you should see a confirmation that it wrote a certain number of lines of text to the file. Now, press control+X on your keyboard to exit the hosts file.
- In the Terminal window, type sudo killall -HUP mDNSResponder and press return.
B: Windows 11
- Click your Start button.
- Type Notepad into the search field, but do not press Enter.
- In the search results, right-click on Notepad and choose Run as administrator.
- If prompted by User Account Control, click Yes.
- Click File and choose Open.
- Navigate to C:\Windows\System32\drivers\etc. In the bottom right-hand corner, use the drop-down option to show All files.
- Open the hosts file.
- Make any necessary changes.
NOTE: Entries that begin with the pound sign (#) are for comments or examples. They act as if they are not there. For entries to work, do not use the pound sign (#). - Click File and choose Save.
Outcome
Your computer will use the information in the hosts file to translate host names to IP addresses.