How to do host entry in Windows?

Changing host entry for a specific domain means you are overriding the domain name system (DNS) for specific machine. This is useful to test your site without making your site live. This change will run your specified website directly at the Internet Protocol (IP) address that you specify in your machine host file.

Follow these steps to make changes on Windows:

1. Press the Windows key.
2. Type Notepad in the search field.
3. In the search results, right-click Notepad and select Run as administrator.
4. From Notepad, open the following file: c:\Windows\System32\Drivers\etc\hosts.
5. Make the necessary changes to the file.
105.105.10.10 freelancergurus.com
105.105.10.10 www.freelancergurus.com

6. Select File > Save to save your changes.

NOTE: Make sure space between IP and domain name will be a “TAB”. If you add a white space then may be your site will not run from specified IP.