Last updated: · By Ryan Walsh
Moving WordPress sites to a new host means copying your files and database to a new server, updating the settings that tell WordPress where it lives, and pointing your domain to the new address. Done in the right order, the move causes little or no downtime. The core steps are to back up everything, build the site on the new host, transfer the files and database, update wp-config.php and the site URL, switch DNS, and then test thoroughly.
Key Takeaways
- Create a full backup of your WordPress files and database before you change anything, as the official WordPress migration guide recommends.
- Build and test your site on the new host before you switch DNS, using a test address that only you can reach.
- If your site address changes, the siteurl and home values stored in the database must be updated to the new address.
- Lower your DNS TTL ahead of the switch so that changes reach visitors sooner.
- When URLs change during a move, map each old URL to its new equivalent and redirect the old URLs to the new ones.
What Does Moving a WordPress Site Involve?
Moving a WordPress site means transferring three things: the files, the database, and the configuration that connects them. Your files include WordPress core, your theme, your plugins, and your uploaded images. Your database holds your posts, pages, settings, and user accounts.
A web host is the company that stores your site on a server and makes it available on the internet. DNS, or the Domain Name System, is the system that translates your domain name into the IP address of the server where your site lives. Moving hosts means changing that IP address so visitors reach the new server.
Why Would You Move WordPress Sites to a New Host?
People usually move because their current host is slow, unreliable, too expensive, or lacks support for WordPress. A new host may offer better performance, stronger security tools, automatic backups, or room to grow. These benefits depend on the plan you choose, so compare plans before you commit rather than assuming a move will improve speed.
How Do You Choose a New Host?
Choose a host by matching the hosting type to your traffic, budget, and comfort with server administration. Shared hosting is the cheapest option but shares server resources with other sites. Managed WordPress hosting adds WordPress-specific support and usually includes updates and backups. A VPS gives you more control and dedicated resources, but you handle more of the setup yourself.
| Hosting type | Best for | Main trade-off |
|---|---|---|
| Shared hosting | Small sites with light traffic and a tight budget | Performance depends on neighboring sites |
| Managed WordPress hosting | Beginners who want WordPress-focused support and automatic backups | Higher monthly cost and sometimes limits on plugins |
| VPS hosting | Growing sites that need more control and resources | You manage more of the server yourself |
For a deeper comparison of plan types, read our guide to exploring hosting options for WordPress websites. Before you sign up, confirm that the new host supports your PHP version and your database type.
How Do You Prepare Before Moving WordPress Sites?
Preparation means backing up your site and building a working copy on the new host before any visitor sees the change. Skipping these steps is the most common reason migrations go wrong. Give yourself a quiet period, ideally during low traffic, to complete the work.

Back Up Your Files and Database
The official WordPress migration guide advises backing up the WordPress directory, your images, your plugins, other files, and the database before making any changes. Store the backup somewhere other than your current server, such as a local drive or cloud storage. You can use a backup plugin or your host’s backup tools, and you should confirm you can restore from the backup. For a comparison of options, see The Ultimate Guide to WordPress Backup Plugins.
Build a Test Copy on the New Host
Google’s guidance on changing hosts recommends creating a testing environment on the new server to check every feature before the site goes live. Restrict access to that environment, for example by allowing only your own IP address, so search engines and visitors cannot index an unfinished copy. Your test copy should include your files, your imported database, and a working configuration. Check it thoroughly before you switch DNS.
How Do You Move the Files and Database?
To move the files and database, download your WordPress files, export the database from your old host, create an empty database on the new host, upload the files, and import the database. Work through these steps in order.
- Download all WordPress files from your current host using an FTP client.
- Export your database using phpMyAdmin or a migration plugin, and save the file.
- Create a new empty database and a database user with full privileges on the new host.
- Upload your WordPress files to the new server, including wp-content, uploads, and plugins.
- Import the database file into the new database and confirm that the import finished without errors.
Download Your Files With an FTP Client
An FTP client is software that transfers files between your computer and a web server. FileZilla and Cyberduck are two widely used free options. Connect with the credentials your current host provides, then copy the entire WordPress root folder to a folder on your computer.
Export and Import the Database
Most hosts provide phpMyAdmin, which lets you export your database as a SQL file and import it on the new server. For large databases, a command-line tool or a dedicated migration plugin can be more reliable than a browser upload. After importing, check that the tables are present and that your post count matches the old site.
How Do You Update wp-config.php and the Site URL?
You update wp-config.php so WordPress connects to the new database, and you update the site URL only if your address changes. The wp-config.php file holds your database name, username, password, and database host, along with security keys and salts.
Edit wp-config.php
Open wp-config.php on the new server and replace the database name, username, and password with the values from your new host. Confirm the database host value, which is often localhost on many shared hosts but may differ on your provider. Replace the authentication keys and salts with new values from the official WordPress secret-key generator to improve security. Save the file and reload the test site to confirm the connection works.
Update siteurl and home
The WordPress Developer Resources migration guide explains that moving a WordPress install to a new server or domain changes its URL, so the siteurl and home values stored in the database must be updated to the new address. If your domain stays the same and only the server changes, these values may already be correct. If you change domains, you can set both values in wp-config.php using WP_HOME and WP_SITEURL, which override the database values. Use a search-and-replace tool that handles serialized data when you change URLs inside the database, because a plain text replace can corrupt stored settings.
You can read the full steps in the official Migrating WordPress guide from WordPress Developer Resources.
How Do You Point Your Domain to the New Host?
You point your domain to the new host by changing the A record in your DNS settings to the new server’s IP address. You make this change at your domain registrar or DNS provider, and it is the step that actually moves live traffic to the new site.

Lower the TTL Before You Switch
TTL, or Time To Live, controls how long other computers cache a DNS record before checking for an update. Google recommends lowering DNS TTL values before the switch so that the change spreads faster. A value of 300 seconds is a common choice. Lower the TTL at least a day before the move, wait for the old value to expire, and then make the change.
Update the A Record and Related Records
Log in to your registrar, find the A record for your domain and any subdomains, and replace the old IP address with the new one. Changing the A record does not move your email. If email runs through the old host, its MX records need separate attention to avoid lost messages. Clear your local DNS cache afterward so you see the change sooner.
Propagation time varies. Changes often appear within a few hours, but some visitors may still reach the old server for up to 48 hours depending on cache settings.
Do You Need Redirects When Your URLs Change?
You need redirects whenever the address of a page changes during a move, such as when you switch domains or change your permalink structure. Google recommends preparing a URL mapping from each old URL to its new equivalent and configuring the server to redirect old URLs to the new ones. Use permanent (301) redirects so search engines transfer signals to the new addresses.
Create a simple spreadsheet with the old URL in one column and the new URL in the other, then add the redirect rules to your server or a redirect plugin. Read the official Google Search Central guidance on site moves with URL changes before you begin. If your permalinks also changed, review our guide to optimizing WordPress permalinks to choose a clean structure.
How Do You Test the Site After the Move?
Test the site by checking its functions, plugins, pages, and speed on the new host, both before and after the DNS switch. Work through a checklist so you do not miss anything.
- Log in to the WordPress admin and confirm you can edit and publish a test post.
- Click through key pages, menus, forms, and checkout or contact features.
- Confirm that every plugin is active and that no plugin shows an error.
- Check images, media uploads, and embedded content for broken links.
- View the site on mobile and desktop browsers, and check that the layout displays correctly.
- Measure page load times and compare them with your old site.
- Confirm that your SSL certificate is active and that the site loads over HTTPS.
What Are Common Migration Problems and Fixes?
Most migration problems come from incorrect database settings, outdated URLs, file permissions, or DNS caching. The table below matches common symptoms with their usual causes.
| Symptom | Likely cause | Fix |
|---|---|---|
| Error establishing a database connection | Wrong database name, user, password, or host in wp-config.php | Compare each value with the new host’s database details and correct them |
| Redirect loops or mixed content warnings | siteurl or home still points to the old address or uses the wrong protocol | Update siteurl and home and replace hardcoded old URLs |
| Missing images | Uploads folder not transferred, or URLs still point to the old domain | Re-upload the uploads folder and run a search-and-replace on URLs |
| Permission errors when uploading or updating | Incorrect file permissions on the new server | Set folders to 755 and files to 644, as commonly recommended for WordPress |
| Pages return 404 errors | Permalinks not refreshed or redirects missing | Go to Settings, Permalinks and save the settings, then add redirects for changed URLs |
| Visitors still see the old site | Cached DNS records or a high TTL | Wait for propagation, clear local DNS cache, and confirm the A record is correct |
If a plugin causes errors after the move, deactivate all plugins and reactivate them one at a time to find the culprit. If you run into data loss, restore from your backup rather than trying to repair the database by hand. For a broader set of fixes, see troubleshooting common WordPress errors for beginners.
How Do You Clean Up After Moving WordPress Sites?
After the new site runs well for several days, you can cancel the old hosting plan, but keep a copy of your backup for a while longer. Confirm that your SSL certificate is active on the new host, and if it is not, follow our guide to steps for turning on HTTPS with a free SSL certificate. Update any services that depend on your old server, such as analytics, email sending, and third-party API keys.
Frequently Asked Questions
How long does it take to move a WordPress site?
Many small sites can be moved in an afternoon once you have a host and a backup ready. Larger sites with big databases or many media files take longer, especially during the file upload and database import steps. Most of the delay usually comes from testing and waiting for DNS changes to spread.
Will moving my WordPress site hurt my SEO?
A move does not have to hurt your SEO if your URLs stay the same or you redirect every changed URL to its new equivalent. Google advises a URL mapping and server redirects when addresses change. Keeping your content and internal links intact also helps search engines recognize the site after the move.
Do I need to reinstall WordPress on the new host?
You can install a fresh copy of WordPress on the new host and then upload your files over it, or you can upload your existing files and import your database. Either approach works, but make sure the WordPress version and PHP version on the new server are compatible with your theme and plugins. Avoid mixing files from different WordPress versions.
Can I move my WordPress site without downtime?
You can greatly reduce downtime by building and testing the site on the new host first, lowering your DNS TTL in advance, and switching DNS during a quiet period. Some visitors may briefly reach the old server while DNS spreads, so keep the old site running until the change has settled. Downtime is not always fully avoidable, but it is usually short when you plan carefully.
Do I need to update my email when I move hosts?
Yes, if your email runs through your old host or your domain’s MX records point there. Changing the A record for your website does not move email on its own. Before you switch, confirm where your mail is hosted and update the MX records or migrate mailboxes so messages keep arriving.
Conclusion
Moving WordPress sites to a new host is manageable when you follow a clear order: back up, build and test on the new server, move the files and database, update wp-config.php and the site URL, lower the TTL, switch your A record, and then verify everything. Keep your backup until the new site has run smoothly for several days. With careful preparation, you can change hosts while keeping your content, your search visibility, and your visitors’ experience intact.
More on Moving WordPress sites
Related guides: The Ultimate Guide to WordPress Backup Plugins" · Exploring Hosting Options for WordPress Websites · How to Install WordPress on cPanel or Localhost
Free tools: How Much Does a WordPress Site Cost? Free Calculator
