At some point in time most people become fed up with their current hosting provider and set out to move to a new hosting company. Many people do not realize how much work is involved with moving a website from one web host to another. Since I just finished moving a few dozen websites I thought I would blog about the proper steps to make things go as smoothly as possible with a website transfer. If you’ll follow these steps you will avoid some of the most common pitfalls.

The first and most important step is to backup all of your website files to your local computer or laptop. Be sure to backup image files as well as any html and php files. If your site has a mySQL database you can dump the DB as well, either in ZIP format or as a .sql file. If you have created several email addresses it is a good idea to write them all down, including the passwords for POP3 so recreating them will go smoothly.
The next step is to choose a new web hosting company. If you haven’t already selected your new host be sure to find one with a similar control panel to what you have been used to. This will minimize the learning curve and help speed things along. If you don’t mind learning how to use a new hosting control panel then the field is wide open.
Once you have selected your new web hosting provider, I like to login to the control panel and create the email accounts first. A common mistake is to forget this step until you have switched DNS and start wondering why you are no longer recieving emails. This can be disastrous if your emails are mission-critical to your site or web business. Try to keep the same passwords if you have several employees using POP email accounts. Otherwise, you will waste half a day setting up everyones Outlook accounts for them.
After your email accounts have been created, you are ready to upload the site files. Make sure you set the directory to the correct name as many hosting companies have different defaults (ie: public_html/, httpdocs, var/www/html/, etc.). This can cause a lot of problems if you upload all the files to the wrong directory. If your site has a database you will need to recreate the Tables and Users. If you dumped your database correctly you will have the structure and data intact. If your moving a blog there may be other steps necessary, sometimes you have to re-install the blog software.
After your email accounts are created, site files are uploaded and mySQL databases recreated you are ready to test. Most hosts will give you a test URL when you signup, if you have a dedicated IP address you can type that into a browser to test the functions of your website. Make sure that all the files are uploaded and all the links are working. Sometimes you may have to set permissions on certain directories to get things working right. Get it right, because once you switch DNS all of your mistakes will be amplified and public for all to see.
Once you are convinced that you have covered all the bases, you are ready to switch the DNS over to point to your new host. Once you switch the DNS it can take up to 48 hours for the changes to propogate across the internet. A recent site I transferred took 3 whole days, while less than 12 hours is the norm. If possible I like to move to a new host at least 30 days before my old account is expired. This gives you a little wiggle room if something goes wrong.
If you missed a step and broke your website badly you can simply switch the DNS back to the old host for a few days while you get things fixed. If you got lucky and everything works then it is likely that nobody even knows you have switched web hosting companies. It should be seemless even to your employees if their email accounts were setup properly.
The last step is to contact your web host and cancel your old hosting account. If you have any remaining days on your hosting plan, you can usually get some of your money refunded to your credit card. Don’t count on it though.
