How to move a WordPress website from a temporary domain name to your live domain
Why would you use a temporary domain name?
When your domain name is in use with a live website, and you are wanting to develop a new website you will be using a temporary domain name.
This will allow you to host a new installation of WordPress and work on your website, without interrupting your live website.
How to move from a temporary domain to your live domain
These instructions have been designed for people who have been given a temporary domain by their hosting provider, created a new website “behind-the-scenes” and are now ready to go live and replace the existing website.
If you have created a website with a temporary domain name, you need to replace all links within your website with the actual live domain when you want to make the switch over, otherwise you will have broken links, images may not show, and menus may not work.
I have tried to make these instructions as simple to follow as possible – without all the jargon.
Step 1 – DNS (Domain Name Settings)
Ensure that your domain name DNS settings have the A and www records pointing to the correct IP address.
If your domain and hosting have been set up together with the same provider, this should not be an issue.
Where do I get the IP address from?
Ask your hosting provider what the A and www records for your website need to be set to.
Where do I check/change the A and www records?
Ask your domain name provider/registrar to change your settings to reflect the requirements from your host.
Step 2 – install Better Search and Replace plugin
This plugin is gold. It does a search and replace throughout your website.
- Go to Plugins > Add New > search for Better Search and Replace
- Install and activate the plugin
(If you would like to add the plugin manually, you can download it here)
Step 3 – update URLs
- Go to Tools > Better Search and Replace
- Enter your complete temporary URL in the “Search For” field (remove any trailing /)
- Enter your complete new/live domain URL in the “Replace With” field (remove any trailing /)
- Select all files in the box
- Click “Run Search and Replace” button
- Allow the dry run to complete. If there are no errors, untick the Dry Run box and click “Run Search and Replace” again.
Step 4 – update theme options
If you have logos, headers or other page layouts set up via your Theme dashboard, you may need to update URLs here.
Check through your settings.
If you do happen to miss any, you can come back and do these later.