How to migrate a WordPress website to another domain?
Steps
- Install the All-in-One WP Migration plugin on your existing website. Click on the “Export” option and it will create a backup. Download this file to your local computer.
- Install the All-in-One WP Migration plugin on your new domain website. Click on the “Import” option and upload the backup file that you downloaded.
- In WordPress admin dashboard, Settings » General, channge the WordPress Address (URL) and Site Address (URL) to new domain url.
- There may be some links inside your posts that go to other webpages on your own website. These links will still have the same old domain URLs, and you need to replace them. For this, you will need a plugin called Search & Replace Everything for easy update of URLs of links inside your posts.
- On the old existing website, set up permanent redirect to the new domain website. This helps to keep your SEO ranking. Update and notify Google on Google Search Console that the old site has moved to a new site.
- Check everything and done!
And that’s it! You’ve successfully migrated your WordPress website to a new domain! Moving your website can be achieved with minimal costs and some effort, provided that you have a backup of the original site.
Note
Depending on your hosting provider (such as Hostinger), you may have to access to certain features provided by your host to make website migration easier.
For example,
Copy a WordPress Website to Another Domain Name. This will duplicate the original WordPress website on the new domain. All the website information, such as new domain name and links, will be updated automatically.
Connect a different domain to your existing website. On the selected website, click “Change domain” and viola. This is great when you are starting out and has a second thought which domain name to use.
If you use a decent migration plugin, the new domain should be detected and all internal urls updated automatically. But you need a plugin that explicitly says “migration” in the features, not just a regular backup plugin. Some backup plugins have migration add-ons.
FAQ
Why are my WordPress Address and Site Address fields greyed out?
If the WordPress address (URL) is greyed out on the settings page of your admin area, then it means the URLs are hardcoded in the wp-config.php file. It is important to note that values in wp-config.php override the settings in your WordPress admin screens. You can access the file from the file manager of your hosting provider or need to FTP into the file server to change it.
WP_SITEURL allows the WordPress address (URL) to be defined.
define( 'WP_SITEURL', 'https://example.com/wordpress' );
More:
How to recreate permalinks on WordPress in case of changing the domain name might cause webpages, except the main one, to display a 404 Error.