How to change WordPress domain name

How to change WordPress domain name

Changing the domain name on which your website is loading can be really frustrating. And at the same time it is common resolution for when you purchase a new domain, when you decide to change the name of your business, or just transfer the website.

In this article we will provide you with step by step instructions on how to change the domain for your website.

  • However it is important to make a backup of your website and database before making any changes on the website!

After you made a backup of your website you can proceed with the domain change which can be done in three ways. Find the one which is most suitable for you and follow the steps:

Change domain from the admin area of your website

You can change the URL from which your website will load when you access the admin area of your website( Go to Settings → General

Change the values under “WordPress Address” and “Site Address” with the one you want to use and scroll down to click on “Save changes”. However, keep in mind that after saving the settings the website will be accessible from the new domain.

Change the domain name using the wp-config.php file

In order to change the domain by using the wp-config.php file you will have to access your account where your content resides(cPanel). Once you access your account navigate to the root folder of the domain and locate the wp-config.php file and lick “Edit”

You will have to add the following code in the file:



Where “” is replaced with the domain which you want to use. The file should look like this after the change:

Click on “Save” and you are ready.

Change the domain name using the database file

The last option is the one with most steps. However, if you follow them properly you will be able to change the domain for your website. To proceed you will have to access the account where the content and database of your website reside(cPanel) and access the phpMyAdmin tool. Once you access the tool locate the database file of your website and click on the database:

You will then have to click on the Options table from the column on the left or on the right. It will take you to one and the same page:

After you open this page you will have to change the value of the siteurl and home column. This can be done when you double-click on the “option_valued” column over the URL. Change the domain with the new one and hit “Enter” to save the changes. Make the same for the second record.

That is all, your website is now loading from the new domain.

How to change the domain name if you are using our Managed WordPress account

First thing to do is access your Managed WOrdPress account with us:

After that hover over the TMD logo and go to Websites. Click “Manage Website” on the website which domain you want to change. Once inside navigate to the tab “Site Settings:

After you access that tab choose the “Domain” option as shown in the screenshot.

From the drop-down menu you can choose the domain which you would like to use and click on “Confirm new domain”.

  • It is important to check that the domain name which you want to use is added to your account, also that it is loading from our servers.