How to Change domain name of WordPress site might sound technical, but it’s actually manageable—especially when you know what to look out for. Maybe you’re rebranding your business, switching from a test domain to a live one, or just finally snagged the perfect .com. Whatever the reason, this guide will walk you through how to change your domain name properly without breaking your site.
I’ve worked with WordPress hosting for over a decade, and one thing I always tell site owners: changing a domain name isn’t just about updating the URL. You need to make sure your SEO, site structure, and hosting settings are aligned too.
So let’s get into it.
Why Would You Want to Change Your Domain?
Before we dive into the “how,” let’s talk about the “why.” Here are a few common reasons:
- Branding upgrade: You’re moving from a generic domain like mybusiness123.wordpress.com to a custom domain like mybrand.com.
- Business name change: Your business evolved and the old domain no longer represents your services.
- Domain extension switch: You may want to move from .net or .org to a more popular .com.
- Merging with another website: You’re consolidating content under a new domain.
Whatever the reason, the process is the same. Let’s walk through it.
Step 1: Back Up Your WordPress Site
First things first—back up your site. You’re making a major change, and the last thing you want is to lose your content, plugins, or media files. Use a plugin like UpdraftPlus, BlogVault, or manually back up through your hosting panel.
If your site is hosted on a managed WordPress platform like Rocon (which supports container-based hosting), you can usually trigger a full site backup from the dashboard.
Step 2: Add the New Domain to Your Hosting
Before anything happens in WordPress, your hosting environment needs to know about the new domain.
- Log in to your hosting panel.
- Add your new domain to your site settings or as an alias.
- Point your new domain to your host’s DNS (usually done via your domain registrar).
- If using Rocon or a container-based host, simply map your domain via the custom dashboard and update DNS records as provided.
Once your DNS records propagate (this might take a few minutes to a few hours), your new domain will start resolving to the host.
Step 3: Update the WordPress Address
Now it’s time to tell WordPress about the change.
Option 1: From the WordPress Dashboard
- Go to
Settings
→General
. - Update the WordPress Address (URL) and Site Address (URL) to your new domain.
- Save changes. You’ll be logged out and need to log in again with the new domain.
Option 2: Via wp-config.php (if the dashboard method doesn’t work)
You can also hardcode the new domain:
phpCopyEditdefine('WP_HOME','https://yournewdomain.com');
define('WP_SITEURL','https://yournewdomain.com');
This can override dashboard settings, so use it if you’re locked out or dealing with migration issues.
Step 4: Update URLs Across the Website
Changing the site address won’t automatically update all internal links, media paths, or shortcodes.
To fix that:
- Use a plugin like Better Search Replace or Velvet Blues Update URLs to search for your old domain and replace it with the new one.
- Be sure to back up again before running the find-and-replace.
These tools will update URLs inside posts, pages, widgets, and even database entries.
Step 5: Set Up 301 Redirects (Critical for SEO)
If you don’t want to lose your search engine rankings, 301 redirects are non-negotiable.
- Set up 301 redirects from the old domain to the new one in your
.htaccess
file or through your host’s control panel. - Example for Apache server:
apacheCopyEditRewriteEngine On
RewriteCond %{HTTP_HOST} ^olddomain\.com$ [OR]
RewriteCond %{HTTP_HOST} ^www\.olddomain\.com$
RewriteRule ^(.*)$ https://newdomain.com/$1 [R=301,L]
This will automatically forward old URLs to the new domain, preserving SEO juice and user experience.
Step 6: Notify Google and Update Tools
You want Google to know about this move. Do the following:
- Log into Google Search Console, add the new domain as a property.
- Use the Change of Address tool in Search Console to let Google know the site moved.
- Update your domain in Google Analytics, Facebook Pixel, LinkedIn, and any other tracking or marketing tools.
Also update your sitemap and resubmit it to search engines.
Final Thoughts
How to change domain name of WordPress site isn’t just a quick edit—it’s a strategic move. When done right, it strengthens your branding and doesn’t hurt your SEO. When done wrong, it can break your site or bury your rankings.
That’s why I always recommend using reliable hosting (like containerized hosting from Rocon or similar platforms) that lets you handle DNS, backups, and SSL smoothly.
So take it one step at a time, double-check everything, and don’t skip your backups. Your new domain name can open a lot of doors—just make sure your transition is clean and well-executed.