Migrate your WordPress site to a new domain successfully

By Monisha Wamanker Posted Category Guides and resources Topics UpdraftPlus, WordPress,

Key points:

  • Always create a complete backup of your WordPress site before migration to prevent data loss.
  • Choose between plugin-based migration (like UpdraftPlus) for simplicity or manual methods (wp-config edits, phpMyAdmin) for more control.
  • UpdraftPlus simplifies domain changes with its search and replace tool that properly handles technical elements like serialised data.
  • Post-migration requires troubleshooting common issues like redirects, broken links and 404 errors to ensure site functionality.
  • For combined domain and hosting migrations, UpdraftPlus Premium offers direct site-to-site capabilities with just a few clicks.

Moving your WordPress site to a new domain can feel like navigating a minefield. One wrong step and you risk broken links, lost SEO rankings, or worse, a completely non-functional website.

Yet domain migration doesn’t have to be a stress-inducing experience.

Whether you’re rebranding or optimising your domain name, our guide will walk you through each critical step of migrating your WordPress site safely and efficiently.

This includes knowing how to create proper backups to protect your valuable content, choosing between plugin-based and manual migration methods, implementing a strategic process to minimise downtime and performing essential post-migration checks to ensure everything works on your new domain.

Assuming you’ve already secured your new domain and are ready to make the move, it’s time to start migrating your WordPress site with confidence!

Essential preparation: backing up your WordPress site before migration

Section titled Essential preparation: backing up your WordPress site before migration

Think of your website backup as an insurance policy – you hope you’ll never need it, but you’ll be incredibly grateful it exists if something goes wrong.

UpdraftPlus makes this process straightforward. All you need to do is:

  1. Install the plugin.
  2. Navigate to the settings page.
  3. Click “Backup Now”.
Back up your existing site before starting the domain migration process

4. Make sure you select both files and databases to backup your entire site.

5. Once complete, verify your backup by checking the log for any warnings or errors. This step is crucial but is often overlooked.

6. Store your backup in a secure, accessible location, like your Google Drive account.

If you’re using UpdraftPlus Premium, you get additional advantages like scheduled backups, incremental changes (saving time and server resources), database encryption to protect sensitive data during transfer, advanced backup reports and the ability to store backups in multiple locations simultaneously for extra security.

The premium version also enables direct site-to-site migration, connecting your sites once and migrating back and forth with minimal clicks, which can be perfect if you anticipate multiple migrations or if you’re moving a site into a WordPress multisite network.

WordPress migration methods: manual process vs. plugin solutions

Section titled WordPress migration methods: manual process vs. plugin solutions

When changing your WordPress site’s domain, you’re faced with two distinct paths: the manual method or using specialised migration plugins. Each has its place depending on your technical comfort level and specific requirements.

The manual approach involves exporting your database, downloading your files, manually updating URLs in your database and reconfiguring your WordPress installation. While this gives you complete control, it’s time-consuming and requires technical expertise with databases and WordPress file structures.

Plugin-based migration dramatically simplifies the entire process. Instead of juggling database queries and file transfers, plugins like UpdraftPlus handle the technical heavy lifting automatically. What might take hours manually can be completed in minutes with the right plugin:

The website was migrated in about 5 minutes total. Updraft is a well-made plugin that just works.

Art P – Customer testimonial.

UpdraftPlus stands out in this category with over 3 million active installations and consistently high ratings. The plugin’s search and replace functionality properly handles complex database elements like serialised data that often trip up manual migrations.

Granted, there are other migration plugins too, but none match UpdraftPlus’s combination of simplicity, reliability and comprehensive features that protect your site during this critical transition.

1. Straightforward domain migration with UpdraftPlus

Section titled 1. Straightforward domain migration with UpdraftPlus

Let’s be clear about what we’re tackling here: you’re keeping your WordPress site on the same server with the same hosting provider, but giving it a new domain name. The website files and database aren’t moving. Only the domain name is changing.

Ensure that you’ve taken a backup using UpdraftPlus before any work is performed on a site. Then, follow these steps:

1. Modify your wp-config.php file. First, you need to ensure WordPress can be accessed during the transition. Add these two lines to your wp-config.php file (replace example.com with your new domain):

define('WP_SITEURL', 'https://example.com');
define('WP_HOME', WP_SITEURL);

2. Access your WordPress admin. With these temporary lines in place, you should be able to log into your WordPress dashboard, even while DNS changes are propagating.

3. Launch the UpdraftPlus search and replace tool. 

  • Navigate to the UpdraftPlus dashboard.
  • Locate the “Advanced Tools” section.
  • Here you’ll find the “Search and Replace” database tool.
The search and replace tool in UpdraftPlus

4. Execute the domain replacement.

  • Enter your old domain in the “search for” field and your new domain in the “replace with” field. This will locate every instance of your old domain across your entire database.

5. Run the operation. Click to execute the search and replace. UpdraftPlus will methodically update all references to your domain while maintaining database integrity.

6. Remove temporary code. Once complete, return to your wp-config.php file and remove the two lines you added in step 1. Your site is now properly configured for the new domain.

The advantages of using UpdraftPlus to update your domain

Section titled The advantages of using UpdraftPlus to update your domain

UpdraftPlus easily locates all instances of your domain in the database and updates them, even in hard-to-find places like image paths, widget settings and theme options. This makes the process simple even for beginners.

The tool really proves its worth in handling WordPress’s complex data structures. WordPress stores much of its content as “serialised data” – a special format that includes information about content length and structure. Regular search and replace methods can break this data, causing your site to malfunction.

UpdraftPlus intelligently updates both your domain references and recalculates all the associated metadata, keeping your database intact and functional. This thorough approach converts what could be hours of painstaking database work into a simple operation that takes just minutes to complete.

2. Alternative methods to move your WordPress site to another domain

Section titled 2. Alternative methods to move your WordPress site to another domain

While UpdraftPlus offers the most full-fledged and foolproof solution, some site owners prefer alternative approaches. These manual methods give you direct control over the domain change process but require careful execution and technical understanding of WordPress’s structure.

Let’s explore three alternative paths for those who prefer to minimise plugin usage or simply want to understand what’s happening under the hood.

Using the WordPress admin dashboard

Section titled Using the WordPress admin dashboard

This is the most straightforward manual approach:

1. Log in to your WordPress admin dashboard.

2. Navigate to “Settings > General”.

3. Update both the “WordPress Address (URL)” and “Site Address (URL)” fields with your new domain.

Changing the site and WordPress address URL settings to the new domain

4. Save changes.

5. You’ll likely be logged out after saving and will need to log back in using the new domain.

While this approach seems simple, it can sometimes create a locked-out situation if the DNS hasn’t fully propagated or if your site configuration has specific issues. That’s why having a backup is critical before attempting this method.

For situations where you can’t access your WordPress dashboard, modifying the configuration file provides a solution:

1. Access your site files via FTP or your hosting file manager.

2. Locate and edit the wp-config.php file in your site’s root directory.

An example of what your wp-config.php file might look like

3. Add these two lines before the “That’s all, stop editing!” comment:

define('WP_HOME','https://yournewdomain.com');
define('WP_SITEURL','https://yournewdomain.com');

4. Save the changes.

This method provides the most direct access to where WordPress stores domain information:

  1. Access phpMyAdmin through your hosting control panel.
  2. Identify your WordPress database (check wp-config.php for a line like define('DB_NAME', 'yourdatabasename')).
  3. Open the database and locate the options table (typically named wp_options, though your prefix may differ).
  4. Find the rows with option_name values of “siteurl” and “home”.
  5. Edit the option_value field for each, replacing the old domain with your new one.
  6. Save changes.

Each of these methods updates your core domain settings, but remember, they don’t handle the complex serialised data that UpdraftPlus automatically manages for you. For most users, the plugin approach remains the safest and most complete solution.

Preserving your site: troubleshooting common WordPress domain migration issues

Section titled Preserving your site: troubleshooting common WordPress domain migration issues

Even the smoothest domain migrations can encounter hiccups. Let’s tackle the most common issues that might surface after your migration and provide clear solutions to keep your site running flawlessly on its new domain.

Clearing your site cache should be your first troubleshooting step – this simple action resolves many lingering connection issues with minimal effort. Beyond that, these targeted fixes address specific problems you might encounter.

Without proper redirects, your SEO rankings will plummet as search engines treat your new domain as an entirely different site. Setting up 301 redirects tells search engines your site has permanently moved, preserving your hard-earned rankings.

The most effective approach:

  • Add redirect rules to your .htaccess file on the old domain.
  • Monitor redirect performance in Google Search Console.
  • Use the Redirection plugin or the wp_redirect function for a user-friendly interface if you’re uncomfortable editing server files.

301 redirects also prevent visitor frustration by automatically routing traffic from outdated bookmarks to your new domain.

UpdraftPlus excels here, as its sophisticated search-and-replace functionality automatically updates URLs during migration throughout your database, ensuring they point to your new domain, saving you time and reducing the risk of broken links from manual updates.

If you’ve used a manual migration method, you’ll likely need to perform additional cleanup:

  • Use a plugin like Better Search Replace to find and update hardcoded URLs.
  • Pay special attention to custom fields and widget content where links often hide.
  • Check the theme customiser settings for domain references.

These frustrating “not found” errors typically stem from permalink structure issues after migration. The quickest fix:

  1. Navigate to “Settings > Permalinks”.
  2. Make no changes to your structure.
  3. Simply click “Save Settings”.
Save permalink settings without making any changes

This forces WordPress to refresh its rewrite rules, resolving most 404 errors instantly.

This alarming blank white screen typically indicates a plugin compatibility issue with your new domain:

  1. Check your email for error details.
  2. Access your site via SFTP or hosting file manager.
  3. Rename the plugins folder (e.g., to plugins_old).
  4. Your site should load without plugins.
  5. Restore plugins one by one to identify the problematic extension.

Images often break during migrations when they use absolute URLs pointing to your old domain. The solution:

  • Convert image paths to relative URLs (/wp-content/uploads/image.jpg).
  • Run another search-and-replace targeting image paths specifically.
  • Check custom CSS for background images that might have been missed.

While Google will discover your domain change naturally, you can accelerate the process:

  • Submit your new sitemap through Google Search Console.
  • Request indexing for critical pages.
  • Update canonical links using Yoast SEO or similar tools.

These troubleshooting steps preserve the value of your website during migration, ensuring visitors and search engines transition seamlessly to your new domain without disruption to your online presence.

Switching web hosting, too? Upgrade to UpdraftPlus Premium

Section titled Switching web hosting, too? Upgrade to UpdraftPlus Premium

Moving your WordPress site to a new domain is one challenge – relocating your entire site to new hosting adds another layer of complexity. This is where UpdraftPlus Premium is worth its weight in digital gold, transforming what could be a technical obstacle course into a streamlined process.

While the free version allows basic migration (backup on source, restore on destination), Premium offers powerful site-to-site capabilities. Connect your sites once, then migrate content back and forth with just a few clicks through the Migrate/Clone interface.

This direct connection is perfect for:

  • Testing changes on staging before pushing to production.
  • Moving from local development to live hosting.
  • Consolidating multiple sites onto one provider.
  • Changing hosting providers with minimal downtime.

UpdraftPlus Premium gives you precision control to migrate specific elements rather than the entire site. It also handles files outside standard WordPress directories (including wp-config.php) and automatically runs clean-up tasks that prevent common migration failures.

For WordPress multisite networks, Premium supports migrating entire networks or individual subsites. Plus, Premium customers receive priority expert support if issues arise.

Of course, manual migration is possible, but why spend hours on complex processes when UpdraftPlus Premium completes the same task in minutes with greater reliability?

Ready to migrate? Get started with UpdraftPlus today

Section titled Ready to migrate? Get started with UpdraftPlus today

Think of domain migration as digital moving day. Just as you’d hire professional movers to transport your furniture without scratches or breakage, your WordPress site deserves the same care during relocation.

UpdraftPlus does the heavy lifting for you here, while you focus on the excitement of decorating your new online home. It reduces hours of technical work to a streamlined process completed in minutes.

Why risk your site’s performance, SEO rankings and user experience with risky manual updates when professional tools exist specifically for this challenge?

Get UpdraftPlus today and experience a migration process that’s refreshingly straightforward and remarkably effective.

About the author

Profile picture of Monisha, the product manager for UpdraftPlus

Monisha Wamanker

Monisha is the Product Manager for UpdraftPlus with over five years of experience in developing user-centric solutions across B2B and B2C sectors. She loves to deliver high-quality products that enhance user experiences. Monisha is passionate about understanding the needs of UpdraftPlus customers, translating them into innovative features that truly help our community to achieve their goals.

UpdraftPlus

Get all our premium features. Direct site-to-site migration, incremental backups, back up automatically before updates and a whole lot more.

From just $70 for the year.

More stories

Our plugins

Try TeamUpdraft’s full suite of WordPress plugins.

  • UpdraftPlus

    Back up, restore and migrate your WordPress website with UpdraftPlus

  • WP-Optimize

    Speed up and optimize your WordPress website. Cache your site, clean the database and compress images

  • UpdraftCentral

    Centrally manage all your WordPress websites’ plugins, updates, backups, users, pages and posts from one location