WordPress Migration Challenges and How to Overcome Them

If you purchase through a link on our site, we may earn a commission. Learn more.

In theory transferring a WordPress website should be a straightforward process that involves few well-defined steps like: export your database from the old host, import it on the new one, move your files, reconfigure WordPress and change the DNS records. Not much can go wrong you may think, but actually on each step things can occur causing trouble and preventing your successful transfer. In this post I will go through the most common of these issues and try to give you tips I learned from migrating hundreds of sites to SiteGround servers.
Table of Contents
WP Engine High Performance Hosting
BionicWP Hosting

In theory transferring a WordPress website should be a straightforward process that involves few well-defined steps like: export your database from the old host, import it on the new one, move your files, reconfigure WordPress and change the DNS records. Not much can go wrong you may think, but actually on each step things can occur causing trouble and preventing your successful transfer. In this post I will go through the most common of these issues and try to give you tips I learned from migrating hundreds of sites to SiteGround servers.

phpMyAdmin Timing Out when Exporting/Importing a Database

Your database is not just a file that can be moved from one place to another. It has to be exported to a “dump” file, transferred and then imported into an empty database on your new host. There are several issues you can face doing this.

The most common one is the phpMyAdmin tool timing-out. Although it is great software, it’s likely that you won’t be able to export a big database. It’s even worse for the import process because the dump file of your database has to be uploaded first.

The good news is that you can get around these issues using WP-CLI and generic SSH commands. One of the main reasons we’ve preinstalled WP-CLI on all our servers for example is that you can simply type:

EXPORT: wp db export for-transfer.sql

IMPORT: wp db import for-transfer.sql

and you will have a backup of your database in no time. If you don’t have WP-CLI installed, but you have SSH access you can use the native command for that:

EXPORT: mysqldump -uUSER -pPASSWORD DBName > for-transfer.sql

IMPORT: mysql –uUSER –pPASSWORD DBName < for-transfer.sql

If that fails to work, timeouts or the command is not available, your last resort is to request a backup of your database to be created by the support team of your old hosting provider, and/or to ask your new host to import the dump file into a new database for you.

Files Taking Ages to Download and Upload

Although it seems trivial, you can definitely face these issues if you have a very big WordPress installation with a lot of multimedia. Most people start downloading their files and folders locally via FTP, and then upload them to the new host. Usually, that takes ages. Here are few tips on how to speed up the process.

First, make an archive of your site files and transfer it. It’s faster to move one big file rather than thousands of small ones. Much, much faster.

Next, if you have SSH access to your new host, login and download your files’ archive directly from your old hosting provider to the new server. This will save you a step of downloading your archive to your local computer and then uploading it, and it will be at least two times faster.

Some hosting providers offer only SFTP access to your account. I personally think that’s not enough to adequately manage a WordPress site. Mostly because you don’t have access to WP-CLI and you can’t execute tasks like the one described above with the same ease.

Configuration Issues after Migration

Once you have successfully transferred your database and files you need to do some reconfiguration in your wp-config.php file and alter the database settings to match your new database name, user and password. After you complete these reconfigurations you should change your DNS settings and in a few hours your domain will start opening your blog from the new location. Unless…something is not working the way it should, which unfortunately happens a lot, especially if you don’t test enough.

It is a good idea to check if everything is OK with your site on the new location before making the DNS change. Almost all providers have direct URLs that you can use to access your account, even if you do not have a domain name associated with it yet. For example, if you’re hosted with SiteGround, that would be something like: . You can add these lines to the functions.php file of your theme to configure WordPress to work from the new location:



Once you make sure that your site is working well, change those lines to your actual domain name. Then, load your website from your actual domain name, check if it is working fine again, and then simply remove the two lines because your home URL is already stored in the WordPress database.

Internal Server Rrrors Due to Wrong File Permissions

Some hosts allow you to have permissions like 777 for your files. When you transfer files from one host to another, their permissions are moved too. Such file permissions present a huge security risk, and if you are switching to a host that cares about security that should result in an “Internal Server Error” page.

SiteGround has 1 click permission fix for all your WordPress files as part of our WordPress Management Toolset. However, if you don’t have such a tool at your disposal, you can manually fix your file and folder permissions via FTP or SSH. It might not be as fast though.

Losing Comments or Other User Activity During Propagation Time

The final step of migrating your website is the DNS change. This part can be tricky too. Domain records changes need the so-called propagation period to take place. This time is required because all the world’s DNS servers need to update their records about your domain name. However, this time is needed only when you edit your domain information like nameservers, admin name, email, etc.

To avoid/decrease the propagation time required, you can edit the DNS Zone on your old host pointing the A record of your domain to the new one. By doing this, even if a visitor is still referring to your old nameserver, he or she will be pointed to the correct new IP address and access the right content.

In addition, while waiting for the propagation period to pass, you can disable the comments on your old hosting account, or even place the old installation in maintenance mode. You can go further and use a plugin like WP Maintenance Mode to create a page telling your visitors that if they see this message, they are loading your site from the old server and advise them to press Ctrl+F5 or Command + R as many times as needed until they enjoy your site from its new host.

If you enjoyed this post, make sure to subscribe to WP Mayor’s RSS feed.

Alyona Galea

Alyona is a WordPress enthusiast, focused on sharing interesting things she comes across during her work with this great CMS. She loves exploring new destinations and maintains a travel blog at www.alyonatravels.com

Discover more from our archives ↓

Popular articles ↓

11 Responses

  1. Good suggestions. I would like to add a few things.
    before taking a decision on whether someone should use wordpress
    plugins or doing migration manually, you have to know the pros and cons of using plugins for wordpress migration.
    1. First and Foremost, Security!
    According to the statistics of CMS users among the World Wide Web, WordPress is being used by 38% of the website owners. Before feeling proud that you are one among them, know that Hackers and Spammers usually target WordPress websites making your site more vulnerable to security hacks & malicious attacks. There are hundreds of plugins configured by Hackers who intend to steal your login information and much more.
    2. Incomplete and inconsistent data transfer
    Issues that arise as a result of a faulty migration can lose your money and
    time. For example, when your site goes disconnected, you lose deals. It
    can hurt your business badly. While you might think that using plugins as a migration tool will improve efficiency by reducing the time, know the fact that most of these migration tool plugins are designed to do the basic transfer of files, which transfer only the files from your document root and not from other folders. For some website owners, they use their emails for many purposes and these emails may contain valuable data which are also required to be transferred along with the website files.
    To know more, read
    Choose a wise decision!

  2. I *hate* that WordPress stores absolute URLs all over the database – surely there should be one master URL (and is that even needed – the home URL should surely be constructed from PHP env vars?) and the rest should be relative URLs.

    If I have to move a site (e.g. dev to UAT to live) or even just convert it to SSL (http to https), all the URLs have to be search and replaced and – as people have said – it’s *not* a simple text string replacement of an SQL dump either – arrgh!

    I now use WP-CLI:

    wp search-replace old_url new_url

    It’s *very* fast, even if there’s 10,000’s of URLs to replace (which can happen, believe you me).

  3. Hi, I just found this article because I’m having a strange issue trying to export my local site to Siteground using Xcloner or Duplicator. All the steps go fine and give no error, but when I try my live installation, no users, no post, pages and medias are there. I’d be really grateful if someone could give me some kind of solution to resolve this.

    Thank you very much

  4. I’ve tried using Xcloner and the transfer works fine – but I get a Cannot connect to database error – even after editing the wp-config.php file. I gather this is a common problem but have yet to find a solution. Any thoughts?

  5. I think this article and service could be useful for WP migration.

  6. I just lost widgets and their content, plugins and more on a recent site migration from a /url test to the full url (different url names though).

    I read a whole ton of posts on the issues and had hoped to avoid them, but I still lost content. Thank goodness it was a small site, with site-wide widgets not page by page. All the same, I’ll devour this post and checklist to ensure it won’t happen again.

    I was on Siteground hosting and using Genesis framework + theme. I am sure that the Genesis thing caused some issues. Has anyone else found Genesis widgets disappear on migration? I did the config and .htaccess all correct, so can’t fathom out why I lost widget content and all my plugin activation.

    1. Probable there were options stored in the database relying on the previouse URL (/test). In such cases It’s a good idea to run a search for the old URL in your entire database, just to be sure that there are no links or options that are still using the old URL. If you’re still having issues, I can take a look into the site too, just tweet me @pandjarov and I’ll send you my email 🙂

    2. Liz, you lost a bunch of data because of differences in the lengths of strings that were serialised and stored in WordPress options. When that happens, doing a search / replace on the .sql file breaks the serialised data because the string lengths really matter. e.g. “https://example.com/test” is 23 characters, “https://example.com” is 18 characters. PHP serialises arrays of string with the string length, and just throws that data away when the lengths don’t match.

      Best off using a tool that understands this, e.g. WP Migrate DB.

  7. Excellent points made in this post. It’s often not as easy as people make out and can get messy very quickly if something goes wrong.

    Command line is powerful, but not everybody will feel comfortable rolling up their sleeves and diving into the terminal.

    Liz – not sure what happened for you there. I’ve migrated plenty of Genesis sites and not had that issue before. Hope you got it sorted ok.

Share Your Thoughts

Your email address will not be published. Required fields are marked *

Claim Your Free Website Tip 👇

Leave your name, email and website URL below to receive one actionable improvement tip tailored for your website within the next 24 hours.

"They identified areas for improvement that we had not previously considered." - Elliot

By providing your information, you'll also be subscribing to our weekly newsletter packed with exclusive content and insights. You can unsubscribe at any time with just one click.