How to Change the Domain Name of Your WordPress Site

How to Change the Domain Name of Your WordPress Site

Sometimes, you may want to change the domain name of your WordPress site. For instance, in a case where you are running your site under a sub-domain but you want to move to a top level domain.

The entire process should not be complicated. This is a step-by-step guide that shows you how to completely change the domain name of your WordPress site without losing your site customization and settings.

Prerequisites

  • A new domain name(e.g.www.example.com)
  • A hosting account
  • Access to the admin section of your WordPress site

Step 1:
Update the DNS settings of the new domain name

Before you begin, backup your WordPress site. Then, make sure you have pointed the DNS records of the new domain name to the name servers of your hosting account. You can get these values from your hosting provider and they usually start with an ‘ns’ prefix.

For example:

ns1.example.com
ns2.example.com

Remember, DNS server update may take up to 48 hours to propagate so it is good to plan early before time.

Then, you will need to add the new domain under the list of ‘Addon Domains’ on cPanel. If you are running your site from a VPS plan with no GUI (Graphical User Interface), you will need to create a new virtual host and reference your new domain name.

Step 2:
Login to the admin section of your website

Next, login to your WordPress site using the old domain name. Assuming your old domain name is ‘example.com’, enter the URL below on a web browser.

www.example.com/wp-admin

Then, enter your username and password and click ‘Log In’ to proceed.

Step 3:
Update the domain name from the WordPress General settings

Next, go to WordPress ‘Settings’ Menu and select ‘General’ sub-menu. Replace every instance of the old domain name with new values. For instance, if you are changing the domain name from ‘www.example.com’ to ’www.example.net’, enter the values below:

Then, click on ‘Save Changes’ at the bottom of the screen.

If you try to access your WordPress site using the new domain name, you will get a 404 – page not found error. You will have to move all files under the public_html directory of the old domain name to the new domain name.

You can do this using cPanel file manager.

Step 4:
Update permalinks

Next, you need to update permalinks. This time, log in to the admin section of your WordPress site using the new domain name e.g.

$ www.example.org/wp-admin

Then locate ‘Settings->Permalinks’

Then click on ‘Save changes’ on the bottom end of the screen to refresh the URL’s

In case you see broken links on your site, you should install a ‘Search and Replace’ Plugin from the WordPress software repository.

Conclusion

In this article, we have taken you through the procedure of changing the domain name of your WordPress site. As advised above, you should plan earlier to avoid downtime on your site in case DNS propagation takes a long time to be refreshed. If you followed the step-by-step guide accurately, you can now serve your WordPress site from the new domain name.

Special Note: if don’t feel tech savvy enough to do this, it is worth considering  specialized WordPress hosting plan that includes WP support. You can find the highest rated WordPress hosting providers on HostAdvice.

Check out these top 3 WordPress hosting services:

A2 Hosting
£1.49 /mo
Starting price
Visit A2 Hosting
Rating based on expert review
  • User Friendly
    4.5
  • Support
    4.0
  • Features
    4.5
  • Reliability
    4.8
  • Pricing
    4.0
IONOS
£0.76 /mo
Starting price
Visit IONOS
Rating based on expert review
  • User Friendly
    4.5
  • Support
    4.0
  • Features
    4.5
  • Reliability
    4.5
  • Pricing
    4.3
Webdock
£0.80 /mo
Starting price
Visit Webdock
Rating based on expert review
  • User Friendly
    3.8
  • Support
    4.5
  • Features
    4.5
  • Reliability
    4.3
  • Pricing
    4.3

How to Add Additional Domain Names to your Hosting Account using cPanel

This article provides you with step-by-step instructions for adding additional d
less than a minute
Eliran Ouzan
Eliran Ouzan
Web Designer & Hosting Expert

How to Create a Subdomain Using cPanel

This tutorial shows you how to create a sub-domain using the cPanel web hosting
less than a minute
Eliran Ouzan
Eliran Ouzan
Web Designer & Hosting Expert

How To Change a Domain Name in cPanel

This tutorial is written to show you how to change or modify the domain name in
less than a minute
Eliran Ouzan
Eliran Ouzan
Web Designer & Hosting Expert

How to Edit the CSS for your WordPress Site Using the cPanel Hosting Control Panel

As you know, the design of a WordPress website is controlled by
less than a minute
Eliran Ouzan
Eliran Ouzan
Web Designer & Hosting Expert
HostAdvice.com provides professional web hosting reviews fully independent of any other entity. Our reviews are unbiased, honest, and apply the same evaluation standards to all those reviewed. While monetary compensation is received from a few of the companies listed on this site, compensation of services and products have no influence on the direction or conclusions of our reviews. Nor does the compensation influence our rankings for certain host companies. This compensation covers account purchasing costs, testing costs and royalties paid to reviewers.
Click to go to the top of the page
Go To Top