Test your site before changing hosting companies

We frequently get asked, "how do I test my site before switching". As a result, we figured it was time to write a short synopsis of how we like to test sites without altering any production or live sites. 

/etc/hosts

We use macOS. The history of macOS X is long and has it's roots in Unix. Part of being a Unix-based OS, means that there is an /etc/hosts file. This file translates domain names to IP addresses. You can read more about these files on Wikipedia. Therefore, the easiest way to test your site on Chillidog before migration is to tell your computer, "hey, don't connect to that old host for my site. Try this happening new web host instead." That's what we will do today :D

Manual editing

You may manually edit your /etc/hosts file using an application like BBEdit or command line editor like VIM, VI, EMACS or nano. Many of these editors are free to use. Editing this file manually will require sudo access. If you're not comfortable with any of these terms, I recommend jumping to the next section regarding HostBuddy. Otherwise, the process for editing this file on Unix/macOS is:

  1. Open Terminal.app
  2. Type sudo vim /etc/hosts
  3. Enter your computer password when specified
  4. Enter your IP address and domain name in the proper format
  5. Hit esc to exit editing mode
  6. Hold the shift key and hit 'Z' twice to save changes
  7. Flush your DNS Cache

Flush DNS Cache

After editing your /etc/hosts file it is necessary to flush your computer's DNS Cache. Some instructions for performing this for different operating systems is outlined here.

HostBuddy

If you're an app type, we recommend HostBuddy. It makes it simple to modify your /etc/hosts file. Simply enter your domain and the IP address you received in your New Account Info email. If you need us to re-send you this email, let us know. After entering your domain and IP address, simply click 'Apply' and you're good to go. You can then visit your website in your browser as you would normally. All pages and content that you see will be downloaded from your new host instead of your existing host. Remember, this only applies to your computer and no one else on the internet! When you're done, you can simply un-check the "New Hosts" item in the sidebar on the left.

Modify your /etc/hosts file using HostBuddy

  • hosting, migration
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Creating a SQL database

Creating SQL Databases MySQL is by far one of the widest used and most popular database...

Setup 2-Step Verification

2 step verification (also known as two-factor authentication) adds an extra layer of protection...

Update Contact Information

It is important that your contact details and billing information are kept up-to-date at all...

Upgrade, Downgrade or Cancel Hosting Accounts

You can easily upgrade, downgrade or cancel your Chillidog Hosting account at anytime in your...

Changing Your CPanel Password

You can easily change your CPanel (control panel) password at any time yourself. This is...