Most Popular
Recently Added
Recently Updated

How do I view my website on the new server using my PC's host file?

You've moved your site to the new server but it's not yet live (since the DNS hasn't been transferred). You can view your website on the new server by editing a file on your computer. Try either of these two applications:


If the software listed above is no longer available or not working for you, you may manually edit your local hosts file to force your PC to temporarily resolve the domain name to a different IP address by doing the following:

  • Windows: Edit the file
    C:\WINDOWS\system32\drivers\etc\hosts
    You can do this by clicking Start, then Run, then typing notepad C:\WINDOWS\system32\drivers\etc\hosts into the Run box, and clicking OK.

Once you've opened your hosts file, add the following line to the end of the file:

ip_address    domain name

where ip_address is the IP address of your new server and domain name is your website's domain name.

For example, if you were moving your site www.example.com to a web server with an IP address of 5.6.7.8, you'd add the line:

5.6.7.8    www.example.com

Now save the file and quit the editor.

You may verify you are seeing the new server IP by opening a terminal window (Start > All Programs > Accessories > Command Prompt on Windows) and typing:

ping www.example.com

If you see your new server's IP address in the output you are set.

Now open a browser and enter your website's URL in the address bar. This will display the site on your new server.

Once you've verified all is working contact support and work through finalizing the move process.



Properties ID: 000064   Views: 4297   Updated: 8 years ago
Filed under: