This guide will show you how you can change URL for your WordPress-based website. You may find it helpful when moving your WordPress installation from a subfolder or changing the main domain for your cPanel account.
NOTE: Before proceeding with any changes, make sure that you generate a full backup of your website.
There are two ways to change the WordPress website URL: through admin dashboard and database.
To change the website URL in your WordPress admin dashboard following these steps:
1. Log in to your WordPress admin dashboard > Settings > General.
2. Update WordPress Address (URL) line and Site Address (URL) lines and save the changes
- Find the name of your database in wp-config.php file.
2. Go to cPanel > Databases section > phpMyAdmin menu:
3. Click on '+' next to your cPanel username to expand the list of the databases, locate the database for the WordPress website and click on it. Then, select wp_options table (wp_ is the database prefix and it can be different for your installation):
4. Find siteurl and home rows and change both option_value fields to the new domain:
NOTE: if you cannot find siteurl or home rows, check the second page of the options table.
In some cases, changing siteurl and home is not enough. Some references in the database may not be reassigned to a new domain. This will most likely corrupt the working website and highly developed CMS.
If you faced any issues >> please reach out to us right away