Migrating a WordPress site to a new host is one of those tasks that sounds simple and has about fifteen ways to go wrong. Done correctly, your visitors won’t notice a thing. Done wrong, you’re looking at broken links, missing images, a site that works on the new server but not the old one, or DNS pointing at the wrong place entirely.
Here’s the process we use for every WordPress migration — whether it’s a small business site or a high-traffic WooCommerce store.
Before You Touch Anything
Take a Full Backup of the Current Site
Before any migration begins, create a complete backup — files and database — of the site on its current host. Even if your host takes daily backups, create a fresh one manually so you have a known-good snapshot from immediately before the migration started. If something goes wrong, this is what you restore from.
UpdraftPlus is reliable for this and the free version handles full backups cleanly. Download the backup files to your local machine — don’t rely solely on backups stored on the same server you’re moving away from.
Set Up the New Hosting Account First
Create your account on the new host and set up the domain before you start the migration. Most managed WordPress hosts (WP Engine, Kinsta, Cloudways) let you add a domain without it being live yet — the site will run on a temporary URL while you test it. This is how you should work. Never migrate directly to a live domain without a staging environment.
The Migration Process
Step 1 — Export the Database
Log into your current hosting control panel and open phpMyAdmin. Select your WordPress database, click Export, choose the Quick method, and download the .sql file. This file contains all your posts, pages, settings, users, and plugin data.
Step 2 — Copy All Files
Connect to your current server via FTP (FileZilla is free and reliable) and download the entire public_html folder — or wherever your WordPress installation lives. This includes wp-content with all your uploads, themes, and plugins. Depending on your site size this can take a while. Let it run.
Step 3 — Create a Database on the New Host
In your new hosting control panel, create a new MySQL database, a database user, and assign the user to the database with full privileges. Write down the database name, username, and password — you’ll need them in the next step.
Step 4 — Import the Database
Open phpMyAdmin on the new host, select your new empty database, click Import, and upload the .sql file you exported earlier. On large databases this can time out through the browser — if that happens, use a tool like Adminer or ask your host to import via command line.
Step 5 — Upload the Files
Connect via FTP to the new host and upload everything you downloaded from the old host. Once uploaded, open wp-config.php and update the database connection details to match the new database name, username, password, and host (usually localhost unless your host specifies otherwise).
Step 6 — Run a Search and Replace on the Database
This is the step most people miss and the cause of most post-migration broken links. Your database contains thousands of references to your old site URL — in post content, image paths, widget settings, and option values. These need to be updated to the new URL.
Use Search Replace DB — upload it to your new server, run a search for your old URL and replace with the new one, then delete the script immediately after. Never leave it on a live server.
If you’re moving from http to https as part of this migration, run the search and replace twice — once for http://olddomain.com to https://newdomain.com, and once for any hardcoded http:// references to assets.
Test Everything Before Touching DNS
Most hosts provide a temporary URL for your new site — something like newhost.wpengine.com or an IP-based URL. Use this to test the site thoroughly before changing your DNS.
- Does the homepage load correctly?
- Do images appear on all pages?
- Do forms submit and send email?
- Does the WordPress admin work normally?
- Do any WooCommerce checkout flows work end to end?
- Are there any broken links in the main navigation?
Fix any issues you find before going live. This is much easier when the old site is still running and your DNS hasn’t changed yet.
Point DNS to the New Host
Once you’re satisfied everything works, update your domain’s DNS records to point to the new host. Your new host will give you either new nameservers or an A record IP address to use.
DNS propagation takes anywhere from a few minutes to 48 hours depending on your TTL settings. Lower your TTL to 300 seconds (five minutes) a day before you migrate — this means propagation happens faster when you make the change. After propagation is complete and the site is confirmed live on the new host, raise the TTL back to a sensible value like 3600.
Keep the Old Hosting Active for Two Weeks
Don’t cancel your old hosting the day you migrate. Keep it running for at least two weeks. During that window, some visitors will still be reaching the old server while DNS propagates, you may discover something that needs to be checked against the old setup, and you have a fallback if something goes wrong on the new host.
Once two weeks have passed and everything is confirmed stable, then cancel the old account — and make sure your first backup on the new host is already scheduled and confirmed working before you do.