When you update your domain’s nameservers, DNS propagation can sometimes take from 24 to 48 hours to complete. During this time you can not view your website on the new hosting account. However, you can bypass this and see your website by editing your local host’s files.
Bypassing DNS is to use the hosts file on your local computer. These hosts files contains domain name to IP address mappings.
To use the hosts file to bypass DNS for your domain, follow these steps:
Open the hosts file in a text editor. Ther location it might be different, depends on your computer’s operating system:
- On Microsoft Windows computers, the hosts file is located at \%SystemRoot%\system32\drivers\etc\hosts.
- On Apple Macintosh computers, the hosts file is located at /private/etc/hosts.
- On Linux computers, the hosts file is located at /etc/hosts.
When you open the hosts files you should see the following:
# 127.0.0.1 localhost
To create a new mapping for your domain name, you can add the following:
# 22.214.171.124 domain.com
# 126.96.36.199 www.domain.com
Save this hosts file and close all opened browsers.
When you are done with the steps above, you may need to flush your computer’s DNS. We have a full guide here on how to flush your computer’s DNS.