Migrating your website can seem like a big task, but if you break it down, there are a few things out there that you can use to speed the process along, and make it much easier than you think!
This article works for moving to another hosting company as well as from a sub domain to the main domain.
Most hosting providers install their own custom plugins on your website to ‘help’ you manage it. We recommend that you go into your website directory via FTP, navigate to your plugins folder, and rename the folder or remove it all together.
In the first step, log into the WordPress dashboard on your temporary/sub domain name, go to the Plugins section and click ‘Add New’. Now search for the Plugin called ‘All-in-One WP Migration’ (https://wordpress.org/plugins/all-in-one-wp-migration/) and install it. Once the plugin is installed and activated you’ll need to click on the new ‘All-in-One WP Migration’ tab in your dashboards’s sidebar. There are a few options on this screen. Click on the Find
Then you’ll see the option to export your site. Once clicked it will load all your files and create a file that you can download.
Go to the new server/location where your website will be installed. This is the main domain name that the client has. Install a fresh version of WordPress as normal. Try to make the admin credentials the same as the other website you are developing. This will make it easier to remember for logging in later.
Once you have a clean install of WordPress, go to the Plugins section and click ‘Add New’. Now search for the Plugin called ‘All-in-One WP Migration’ (https://wordpress.org/plugins/all-in-one-wp-migration/) and install it. Once the plugin is installed and activated you’ll need to click on the new ‘All-in-One WP Migration’ tab in your dashboards’s sidebar. This is so you can import the file you exported from the other site.
Navigate to the IMPORT tab of the All In One Menu. If you downloaded the file to your computer, click on IMPORT FROM and select ‘FILE’. If you used the URL method, then you would click on ‘URL’
Once you have chosen your method of restoration, wait for the upload to complete. Once uploaded it will ask you to confirm that database tables and data will be overwritten. Confirm this and wait till the import is finished. (ONCE YOU CONFIRM, DO NOT REFRESH THE PAGE OR NAVIGATE AWAY. CANCELLING THE IMPORT MAY CAUSE ISSUES TO THE NEW WORDPRESS INSTALL AND MAY HAVE THE BE RESET AND STARTED ALL OVER)
One thing that’s important is to keep in mind that when you overwrite the database you also remove your newly setup admin login from your new WordPress site. That’s why we recommend adding the same exact one as before so no there is no confusion.
Once completed, a screen will appear telling you to confirm your permalinks TWICE before continuing. This is necessary as the new install may have had a different setting for this. Click proceed. You will have to re-login again with the credentials from the old WordPress website. Once you do so, navigate to Settings > Permalinks and make sure the settings are correct then hit Save. The page will refresh and you should scroll down and hit save again.
If you made the find and replace change in Step One, skip this step. If you continue to have issues with your old domain name showing on the new site, revisit this step.
Making a backup of your database is recommended. If you are unsure how to, please contact your hosting provider. There are also many plugins that help with doing this.
We want to make sure all your links are correct on your website. You may see some links on the new site that have the old URL. No worries because we are going to take care of that. To resolve that you have to log into your new WordPress installation and go to Plugins > Add New and search for Better Search Replace (https://wordpress.org/plugins/better-search-replace/). Install the plugin and once activated you can access it under Tools > Better Search Replace.
Now you will see several fields. One of them is called Search for and the other Replace with. In the Search for you will type in your old temporary domain name. It is best if you do NOT include the http:// so for example: oldsite.com, in the Replace with field you add your domain for example newsite.com without the http://. Make sure that you select all of the tables that are available and not just some of them. You will see a few checkboxes below that. Make sure the “Run as Dry-Run” is CHECKED. this will allow you to see how many changes need to be made BEFORE actually making them.
Once you are satisfied with the number of tables/cells that will be changes, UNCHECK the dry run box and run the tool. The results will appear at the top of the page telling you how many were changed compared to how many were found.
Once everything has been completed, your website has been successfully migrated! Great job! You are now a master of migrating websites. This tool has help many people and it is what professionals use to move websites quickly and easily. Now go have a drink with all the time you saved.
I have used this plugin on many occasions. I have moved over everything from a 200MB website to a 10GB website with this tool and it was worked flawlessly. I have purchased the URL and Unlimited add-ons just because they are so useful. They are also not restricted by license keys so they can be used on many sites.