If you’ve got a WordPress.org, self-hosted website or blog, the computer, aka web server, where the files for your website “live” belongs to a company that specializes in housing or “hosting” websites by maintaining hundreds of web servers and renting space on them out to companies like yours. These companies are commonly known as web hosting companies or web hosts.

There are hundreds of web hosts out there offering varying features, levels of service and price plans. And, like anything else in the business world, the quality of service can vary wildly among web hosts. As a website owner, there may come a time when you may want to move your site from one web host to another. Why would you want to do this? Several possible reasons:

  • You’re not satisfied with your current host – maybe your site is down a lot, the server has frequent issues or the host network is slow
  • You’ve outgrown your current host – they can’t accommodate the amount of traffic you get or the amount of disk space you need
  • You’ve developed a site on a testing platform and it’s time to move it to a production server elsewhere

I’ve run into each one of these issues at one time or another over the past ten years and chances are very good that you will too. The prospect of moving your website to a new host can be intimidating. Fear of your site being down or losing some of your content is enough to keep many people from making a move. Moving a WordPress website is not a pleasant task, but if you follow some basic guidelines you can minimize the down time and the risk of losing your precious content. In this article I’m going to outline the basic steps I’ve taken to move my WordPress websites.

I’m not going to discuss how to find a web host. I have yet to find a perfect host*. There’s all kinds of conflicting information about web hosts. The nature of web hosting makes it a very competitive industry and the task of keeping web servers safe and secure from black hat hackers, viruses, bots, spammers and other Internet baddies is a daunting one. Different people will have different experiences at the same host. With the ever-changing and varying levels of service available from web hosts out there, I think the best weapon a website owner can have is the knowledge of how to pick up and move if you’re not satisfied with where you’re at.

Do make sure that the new host where you plan to move supports the minimum WordPress requirments for PHP and MySQL. You can get the latest requirements on WordPress.org. In looking at a new web host, you should consider whether your server will use a Linux Apache server or Windows IIS server. My experience is that WordPress can be more difficult to manage on Windows IIS servers.

*The motivation for doing this article is that the web server where this website used to be, kept crashing and having issues, resulting in sporadic and intermittent down time. I had other websites at that same host (Blue Host) and had no problems with those because they were on a different server. I asked the Blue Host multiple times if they could move my site to a different server. But they always had an excuse for not accommodating me. After the most recent bout of this, I got fed up and moved the site to its new host, HostGator. So far, so good. I should mention that I’ve still kept my other sites at Blue Host and they’re still running fine. So, it’s not that the whole Blue Host experience was bad, just that I had the bad luck to have my site on a lemon of a server and they wouldn’t accommodate a reasonable request to move my site for me. So, I had to take things into my own hands and leave them.

Preparing to Move Your WordPress Website

The first thing you want to do is make sure you have all the content for your website. With WordPress, that means you need to have a backup of the database, as well as backups of certain files. You’re going to need to have some FTP software to download these files from the current web host as well as uploading them to the new web host.

Download Files

Using your FTP software, download all your files from the /wp-content/uploads/ folder. A WordPress export should get these, but I like to err on the safe side and get these just in case.

If you have any plugins that have installed new folders, download the contents of that too. For example, the NextGen gallery plugin has a /gallery/ folder in /wp-content/. Get that folder. If you’ve made any customizations to your theme make sure you have those downloaded to your own computer as well. In fact, if you want to play it ultra safe and conservative, just download the whole /wp-content/ folder with all of its subfolders.

If you’re really paranoid and your current WordPress version is older than what you’ll be moving to, you might consider downloading the whole WordPress installation from your current website. I’ve run into issues just updating WordPress versions on one host where I needed to reinstall the old version in order to get in and troubleshoot. Better safe than sorry.

Database Backup

Back-up and export your database. For a lot of simple WordPress sites, using the Tools > Export command in the WordPress dashboard will get you the database content. But some plugins add additional tables to the database and the WordPress exporter doesn’t get those. To get those additional tables I usually export the whole database using a plugin called phpMyAdmin. To learn more about backups of your WordPress database using phpmyadmin, check out my video tutorial article on backing up your WordPress database.

Document Your WordPress Configuration

Downloading your files and exporting your database won’t keep all the information you’re going to need to set up shop on a new web host. Most of your settings in the Settings menu and widget configuration won’t get saved, so you’ll have to reset those when you set up the new installation of WordPress. So, you need to take note of these settings and configurations. Take note of how you have everything configured in your Settings menus as well as any theme-specific configurations like background color or header images. I take screenshots of my widget settings and when I have custom text widgets, I copy all of the text or code in those and paste them into a document so I can easily copy and paste them in when setting up the new site.

Take note of all of your plugins. I take screenshot of my plugins page so I can easily see what plugins I have installed. I likewise take screenshots of plugin configuration pages to document plugin settings and make it quicker and easier to re-establish how everything was on the new site.

Once you think you have everything backed up and documented take a break – for a few hours or preferably a day. Come back and go through everything again after your break to make sure you didn’t forget something.

Ok, now you should have “boxed up” everything and you’re ready to make the move. Now it’s time to start prepping the new place for your site.

Prepping the New Place

Ok, you’ve found a WordPress web host that you think will be good. Sign up for an account with the new web host. You’ll be asked if you need a domain name or if you already have one. You already have one, it’s just currently pointing to your current web host. So, select the option that you already have your own domain name and you’ll be asked to enter that domain name. Make sure you enter it correctly.

Once you’ve signed up you should be given instructions on how to log into your web hosts admin panel. This is a different admin panel than your WordPress admin panel. Many WordPress webhosts use what’s called CPanel to administer various tools and services for your web hosting plan, such as email accounts and software like WordPress.

You’ll want to install WordPress. Hopefully the web host will have a quick and simple automated WordPress installation. If not, you’ll have to install it manually.

Installing WordPress is about as far as you’ll be able to go until you redirect your domain name to the new web host. To redirect your domain name to your new web host, you’ll need to log into where you registered your domain name** and find the option to change the nameservers. Your new web host should provide you with its namservers, something like ns1.newwebhost.com and ns2.newwebhost.com. Enter in these new nameservers.

Now comes the hard part, waiting. The process of re-directing your domain name by changing the nameservers, can take 24 – 72 hours to propagate across the Internet, so that when someone types in your domain name it goes to your new site on your new web host. In practice, I’ve found lately that the change becomes effective within a few hours.

(**Note: if you registered your domain name where you’re site is currently hosted, it would be a good idea to transfer that domain name registration to a neutral domain name registration service. For ease and flexibility in moving web sites from one web host to another, I recommend registering your domain names with a domain name registration service, not a web host. Personally, I like DomainDiscover.com).

Once the nameserver change has taken hold you’ll be able to log in to WordPress and starting moving your site into the new place.

Moving In

Once you have FTP access to your new web host and can log into your new WordPress installation it’s time to move in. The sequence of some of the following steps can be varied, but you’ll need to do all of these steps to get your site looking the way it was.

If you have a customized theme you’ll want to first FTP that theme to your new site into the /wp-content/themes/ folder. By uploading the theme first it will be ready and waiting for you when you log into WordPress.

Log into your new WordPress admin panel. Delete the default post and page that WordPress creates when it installs. Then, import your database export by going to Tools > Import and when prompted select the xml file you exported from your old site. WordPress will then install the WordPress Importer plugin and then lead you through some steps to import your site. Make sure you select to download the attachments.

Activate your theme by going to Appearance > Themes and activating the theme you uploaded.

Configure any theme-specific settings that you may have had on your old site like banner or header images, page background images or colors, etc.

Configure the general settings the way you had them on your old host

Find your notes of all the plugins you had installed and go to Plugins > Add New and install and activate each of those plugins and then go through and configure the settings for each of them to match what you had on your old site.

I usually configure my widgets last after I’ve installed and activated my plugins since some plugins include widgets. Go to Appearance > Widgets and with your notes about your old widget settings, go through and set up your widgets the way you had them on your old site.

Lastly, go through all the pages of your site and a good sampling of your posts and check everything out to make sure everything looks and works as it should. If something doesn’t look right you may have to re-check configuration settings and you may even have to go in and edit some posts and pages, but in my experience that has been rare.

And there you have it. Those are the basic guidelines and steps I’ve used numerous times to migrate WordPress sites from one host to another. Don’t forget that once you’ve changed hosts you’ll need to set up email accounts on the new host to match what you had at the old host as well. Good luck, and if you’ve moved a WordPress site and have any additional tips or guidelines you’d like to share, please feel free to comment.