Changing the domain used by a WordPress website may be necessary when rebranding a project, moving to a new domain name, or consolidating multiple websites under a single brand. WordPress allows you to update the website address directly from the administration panel, making the process relatively straightforward.
Before making any changes, ensure that the new domain is properly configured and points to the same hosting environment as the existing website.
Table of Contents
Step 1: Preparing Your New Domain
Before updating WordPress settings, the new domain must be active and correctly configured.
Register or Configure the New Domain
If the domain was registered through mybox, no additional DNS configuration is usually required.
If the domain was registered with another provider, add it to your hosting account and ensure its DNS records point to the correct hosting environment.
Step 2: Add the New Website in mybox Panel
To associate the new domain with your existing website:
- Log in to mybox Panel.
- Open the Websites section.
- Click Add Website.
- Select Blank Website.
When configuring the website, choose the same directory currently used by the existing WordPress installation.
This allows both domains to point to the same website files during the migration process.
Step 3: Change the Domain in WordPress
Once the new domain is configured, update the WordPress settings.
Update WordPress URLs
- Log in to the WordPress administration panel.
- Navigate to Settings → General.
- Locate the following fields:
- WordPress Address (URL)
- Site Address (URL)
- Replace the existing domain with the new domain in both fields.
- Save the changes.
After saving, WordPress will begin using the new domain for website access and generated links.
Step 3a: Update Existing URLs in the Database (Optional)
Changing the WordPress Address and Site Address updates the website configuration, but existing content may still contain links that reference the old domain.
This commonly affects:
- Images
- Internal links
- Buttons
- Media files
- Custom content created by page builders
To update these references, you can perform a search-and-replace operation on the database.
Using Better Search Replace
If you prefer not to modify the database manually, you can use the Better Search Replace plugin.
The plugin allows you to replace all occurrences of the old domain with the new one throughout your WordPress database.
Before performing any database-wide replacement, it is recommended to create a full backup of your website.
Step 3b: Update URLs When Using Elementor (Optional)
If your website was built using Elementor, additional URL replacement may be required.
To update Elementor URLs:
- Open the WordPress dashboard.
- Navigate to Elementor → Tools.
- Open the Replace URL tab.
- Enter the old website address, including the full protocol (for example,
https://old-domain.com). - Enter the new website address, including the full protocol.
- Click Replace URL.
Elementor will update internal references used by its templates and content.
Troubleshooting
Website Reports a Database Connection Error
If the website displays a database connection error after modifying the domain configuration, verify the database settings in the wp-config.php file.
Check that:
- Database name is correct.
- Database username is correct.
- Database password is correct.
- Database host is correct.
Incorrect database credentials can prevent WordPress from loading properly.
Step 4: Test the Website
After completing the migration:
- Open the website using the new domain.
- Check pages and posts.
- Verify images are loading correctly.
- Test navigation menus and internal links.
- Confirm contact forms and other website functionality are working as expected.
If any links or media still point to the old domain, perform an additional search-and-replace operation.
SEO Considerations
If the website receives search engine traffic, review any SEO-related settings after changing the domain.
This may include:
- SEO plugins
- XML sitemaps
- Canonical URLs
- Search engine verification settings
- External services connected to the website
Updating these settings helps search engines recognize the new domain correctly.
Summary
Changing a WordPress domain through the administration panel involves updating the website URLs, configuring the new domain in mybox Panel, and verifying that existing content references are updated correctly.
After the change is completed, thoroughly test the website to ensure that pages, images, forms, and internal links continue to function as expected.