COVID-19 UPDATE

OUR FULL TEAM IS AVAILABLE ONLINE

We are ready to assist you with any website and digital marketing requirements. Please get in touch if you need a hand.

search

Learn

Abilash
Abilash

The power of using your hosts file

The power of using your hosts file

Posted in How to Guides, Networking, Something Useful, Website Hosting by Abilash on October 28, 2015

If you have had a website for quite some time now and moved service providers or servers or installed SSL there are chances you might have seen a 404 error or a page saying your website’s IP address has changed. The most common reason you encounter this error is when the DNS propagation is not complete. What this means is as simple as your domain name is not translating to the correct IP on which the website works at the moment. To view your website you will have to wait for a couple of hours to a maximum of 72 hours. However, in this post I will walk you through using a file named “hosts” in your PC to bypass DNS propagation wait time. You can also use this method to view a live site on a staging/development server.

All you need at this point:

  • Your domain name
  • Your new IP address
  • Administrator access to the PC you are working from

In our example, let us say our domain name is google.com and the IP is 98.138.253.109 (I’m using one of Yahoo’s IP that is working at the time of writing this blog).

1) Open your note page as an administrator:

notepad-admin

2) Open hosts file:

Hosts file is usually found under C:WindowsSystem32driversetc.
Open-hosts

3) Add the entries:

Add the IP first and then the domain name. If you have additional domain name, enter them on the next line.
hosts-entries

4) You are done!

That is all you had to do. Now go to your browser, clear cache and open google.com and your will be surprised to see the page (shown below).
google-yahoo

Please note that this applies to every Operating System. However the path and the name of the hosts file might vary. The procedure and tools to edit the file may vary. I hope you will find this useful.

Connect with us

Would you like to know the best tools and business resources we recommend?

Connect with us on social media as we share links to news, vital updates and other cool stuff to make you money and save you money.

Learn with us

Now you can learn how to stay on top of change in the digital world. We run workshops and webinars to help our clients and our community. Most of these are free.

Join up for webinar invites

Concise Digital Site Map