Skip to content Skip to footer

How to Migrate a WordPress Site to a New Host

Switching your web host can feel a lot like moving to a new house. In theory, it’s an exciting upgrade to a faster, more reliable neighborhood for your business. In practice, the mere thought of packing up thousands of files, moving databases, and changing system settings can be overwhelming.

The good news is that changing hosting providers doesn’t have to be complicated. With the right preparation and a clear process, you can move your website safely, minimize downtime, and protect the SEO visibility you’ve worked hard to build.

Quick Answer: How to Migrate a WordPress Site to a New Host

The process of moving a WordPress website to a new hosting provider can be summarized in seven key steps:

  1. Create a full backup of your website files and database.
  2. Export your WordPress database.
  3. Transfer website files to the new hosting account.
  4. Import the database to the new server.
  5. Update the wp-config.php file with the new database credentials.
  6. Test the website on the new hosting environment.
  7. Update your DNS records and monitor the migration.

While the process itself is relatively straightforward, proper preparation and testing are essential to avoid downtime, data loss, and SEO issues. The sections below explain each step in detail.

Why Your Migration Strategy Matters

Migrating a WordPress site can feel like moving a glass house across a rocky road. One wrong turn, and you face the “White Screen of Death,” broken database connections, or worst of all, a sudden drop in your hard-earned SEO rankings.

However, staying on a subpar hosting provider is often a bigger risk. Whether you are chasing faster server response times, superior technical support, or better cost-efficiency, a professional website migration is a necessary step for your business growth.

The Goal: A Zero-Downtime Transition

The gold standard of any website migration is simple: your visitors (and Google’s crawlers) shouldn’t even notice it happened. Our primary goal is to transfer every byte of data while maintaining your site’s integrity and search engine visibility. By focusing on a seamless transition, you ensure that the move to a new environment strengthens your digital presence rather than disrupting it.

Key Concept: Manual vs. Plugin Migration

Before we dive into the steps, you need to choose your “vehicle” for this journey:

  • Plugin-Based Migration: Best for beginners and standard sites. Tools like All-in-One WP Migration or Duplicator automate the process, essentially “zipping” your entire site and “unzipping” it on the new server.
  • Manual Migration: The “pro” choice for large, complex sites or those with strict security protocols. This involves manually moving files via SFTP and exporting/importing your database via phpMyAdmin. It gives you total control but requires a bit more technical “under-the-hood” knowledge.

The Migration Fear: What’s Holding You Back?

Whenever webmasters and business owners think about changing servers, the same anxieties crawl up. Many of our clients at DITS.agency ask similar questions before changing hosting providers: “Will my website keep working after the move?” or “Is there a risk of losing data during the transition?” These concerns are completely understandable, especially for business-critical websites. 

It’s a valid fear. A single wrong click during a manual migration can trigger the dreaded “Error Establishing a Database Connection,” wipe out critical customer data, or result in extended downtime that drops your Google rankings. Because of these technical risks, many delay the transition, hurting their site’s loading speed and user experience on an outdated, slow server.

The Solution: 3 Reliable Ways to Move Your Site

You don’t need to be a senior DevOps engineer to handle this process safely. Whether you prefer an automated solution, assistance from your hosting provider, or complete control over the process, there is a migration method that fits your needs.

In this guide, we’ll cover three proven approaches to relocating your WordPress website to a new hosting environment:

  1. The Automated Route: Utilizing specialized WordPress migration plugins to package and deploy your site in a few clicks.
  2. The Hands-Free Route: Leveraging built-in tools to migrate a WordPress site to Hostinger, SiteGround, or other managed platforms seamlessly.
  3. The Pro Route: A complete deep dive into how to migrate a WordPress site to a new host manually using FTP and phpMyAdmin for large, complex websites.

Before we touch a single line of code or log into your web server, let’s start with the absolute golden rule of server migration: preparation.

 

Don’t Want to Risk Your Data? Let the Pros Handle It! 

Website migration can be stressful, and a single mistake can cause critical downtime or drop your Google rankings. If you prefer a 100% safe transition with zero downtime, let our experts do the heavy lifting. Get professional website migration services from DITS.agency today and enjoy a seamless move to your new host. 

WordPress Site Migration to a New Host

Pre-Migration Checklist (Don’t Skip This!)

Think of this phase as your flight safety check. Even if you are using a migration plugin, skipping these steps is the most common cause of “broken” sites after a move.

1. Perform a Full, Verified Backup

Never trust an automated plugin backup alone.
  • The Manual Way: Use SFTP to download your entire public_html folder and use phpMyAdmin to export a .sql dump of your database.
  • The Plugin Way: Use UpdraftPlus or ManageWP to create a fresh snapshot.
  • Pro Tip: Verify the file size of your backup. If it’s 0KB, something went wrong.

2. Deactivate Caching & Security Plugins

Before you create your migration package, disable plugins that interfere with file structure:
  • Caching Plugins: (e.g., WP Rocket, W3 Total Cache). These generate temporary files that will confuse the migration process.
  • Security/Firewall Plugins: (e.g., Wordfence, iThemes Security). They may block the migration plugin’s access to your database or server.
  • Why? These plugins are “server-aware.” Moving them to a new environment without resetting them will likely cause 500 errors.

3. Audit Your Domain & DNS Access

Ensure you have the keys to the castle before you start:

  • Confirm you have direct access to your Domain Registrar (e.g., Namecheap, GoDaddy, Cloudflare).
  • Do not start the migration if your DNS settings are locked or you don’t have the login credentials for your name servers.

4. Benchmark Your Current Speed

You are moving to a new host for better performance, right? Prove it works!

  • Run your current site through or .
  • Record these metrics: Time to First Byte (TTFB), Largest Contentful Paint (LCP), and Total Blocking Time. You’ll want these numbers to verify your new host is actually faster after the migration.

5. Check Your PHP & Database Versions

  • Make sure your new hosting environment supports the same (or newer) versions of PHP and MySQL that your current site uses.
  • Warning: If you are running an outdated PHP version (like 7.4) on your old host and try to move to a server running PHP 8.3, your site will break. Update your site to be compatible with PHP 8.x before you migrate.

You can also read the article – WebSite Migration Checklist

Migrate a WordPress Site to a New Host

Choosing Your Migration Method – How to Migrate a WordPress Site to a New Host

Once you’ve verified your backup, it’s time to choose your path. The method you select depends on your technical comfort level and the size of your database.

Method 1: The Automated Way (Using WordPress Plugins)

If you prefer to maintain full control over the process without touching complex server files, plugins are your best option. This is the most popular answer to the question: Can you transfer a WordPress site to another host without writing code?”

There are several highly reliable plugins built specifically for migrating a WordPress site to a new host:

  • All-in-One WP Migration: Best for beginners with smaller websites. It exports your entire site into a single, proprietary .wpress file.
  • Duplicator: Excellent for mid-sized sites. It bundles your files and database into a zip archive along with an automated installer script.
  • UpdraftPlus: While primarily a backup tool, its premium version allows for direct site-to-site migration.

How to Transfer My WordPress Site to Another Host with a Plugin

Let’s look at the standard workflow using an automated migration plugin:

  1. Install the Plugin on the Old Site. Go to your current WordPress dashboard, navigate to Plugins > Add New, search for your chosen migration tool (e.g., Duplicator), and install it.
  2. Export Your Website Package. Open the plugin settings and run the export/package creation wizard. The plugin will bundle your database, plugins, themes, and media files into a single downloadable package. Download this package to your computer.
  3. Set Up a Fresh WordPress Site on the New Host. Log into your new hosting account and use their one-click installer to set up a clean, blank WordPress site using your temporary URL.
  4. Install the Plugin on the New Site. Log into this new, blank WordPress dashboard, install the exact same migration plugin, and select the “Import” option.
  5. Upload and Deploy. Upload the package you downloaded in Step 2. The plugin will unpack the files, overwrite the blank installation, and accurately reconstruct your original website.

 Important Note on File Limits

Many free migration plugins limit imports to 512MB or 1GB. If you have a massive e-commerce platform or media-heavy blog and are wondering how to migrate a WordPress website to another hosting without hitting these limits, you will either need to purchase a premium plugin extension or switch to the manual method outlined below.

Method 2: The Easiest Way  –  Free Managed Migration

Before you roll up your sleeves to handle FTP clients and database exports, it is worth checking if you can avoid the manual work entirely. Many modern hosting providers want your business so badly that they offer complimentary concierge migration services.

If you are planning to migrate a WordPress site to Hostinger, SiteGround, Bluehost, or WP Engine, these platforms have automated internal migration systems or dedicated support teams that will move your site for free.

How to request a managed migration:

  1. Log into your new hosting control panel.
  2. Navigate to the “Website Migration” or “Migrate Website” section.
  3. Fill out a simple form providing your current WordPress login URL, admin username, and password.
  4. Click submit and let their team handle the rest.

Moving a complex website involves underlying technical risks like unexpected downtime or underlying data loss. If your new host doesn’t offer this service, or if you don’t have the time to handle FTP, databases, and DNS records manually, you can leverage professional website migration services at DITS.agency to ensure a seamless transition with zero downtime and full post-migration QA.

Why Trust DITS.agency with Website Migrations?

At DITS.agency, we’ve helped businesses migrate websites of all sizes  –  from small corporate websites to large WooCommerce stores with thousands of products and complex custom functionality.

Over the years, our team has managed hosting migrations, server upgrades, platform transfers, and website restructures while minimizing downtime and protecting SEO performance. We understand the challenges that come with moving a live website and have developed proven processes to ensure a smooth transition.

The recommendations in this guide are based on real-world experience helping businesses successfully move their websites to faster and more reliable hosting environments.

Method 3: The Pro Way  –  Manual Migration (FTP & phpMyAdmin)

For large-scale enterprise websites, high-traffic WooCommerce stores, or sites with massive media libraries (over 2–5 GB), plugins can frequently time out or crash mid-upload due to server execution limits.

For larger websites with extensive media libraries, custom functionality, or high traffic volumes, a manual migration often provides the greatest level of control and helps avoid limitations imposed by automated tools. 

Complex eCommerce websites often require additional planning during migration. Our WooCommerce Development team helps businesses safely transfer stores, customer accounts, orders, and custom functionality between hosting environments. 

Step-by-Step: How to Migrate WordPress Site to New Host Manually

This method bypasses the WordPress dashboard completely and moves your site directly at the server level using an FTP client and database management tools.

Step 1: Download Your Website Files via FTP

First, you need to grab a physical copy of every file running on your current server.

  1. Download and open a free FTP client, such as FileZilla.
  2. Connect to your old hosting server using your SFTP/FTP credentials (gathered in Phase 1).
  3. Navigate to your root directory – usually named public_html or www.
  4. Select all files, right-click, and download them to a dedicated folder on your local computer. Depending on your site’s size, this may take anywhere from a few minutes to an hour.

Step 2: Export Your Database via phpMyAdmin

While your files are downloading, you need to grab your website’s brain – the database.

  1. Log into your old hosting control panel and find phpMyAdmin.
  2. Select your WordPress database from the left-hand sidebar.
  3. Click on the Export tab in the top menu.
  4. Choose the Quick export method and select SQL as the format.
  5. Click Go. An .sql file will download to your computer.

Step 3: Prepare the New Hosting Environment

Now, switch over to your new hosting account. Before uploading anything, you must create a new, empty home for your database.

  1. Log into your new hosting panel (cPanel, hPanel, etc.) and navigate to MySQL Databases.
  2. Create a brand-new database (e.g., new_wpdb).
  3. Create a new MySQL user (e.g., new_wpuser) and generate a highly secure password.
  4. Crucial Step: Add the user to the database and check the box to grant them All Privileges. Write down these three new credentials: Database Name, Database User, and Database Password.

Step 4: Import Your Database to the New Host

  1. Open phpMyAdmin inside your new hosting panel.
  2. Select the empty database you just created in Step 3.
  3. Click on the Import tab.
  4. Click Choose File and select the .sql file you exported from your old host.
  5. Click Go at the bottom of the page. Once finished, you will see a success message showing that all your tables have been successfully imported.

Step 5: Upload Files and Update wp-config.php

Now, it’s time to bridge the gap. Your files are still on your computer, and they are currently configured to look for your old database. We need to upload them and update their configuration.

  1. Connect to your new hosting server via FileZilla.
  2. Open the new root folder (public_html) and upload all the website files you downloaded in Step 1.
  3. Once the upload is complete, locate the file named wp-config.php in the new server’s file list.
  4. Right-click and choose Edit.

To connect your uploaded files to your newly imported database, you need to replace the old credentials with your new ones. Use the interactive tool below to generate the exact code lines you need to swap out:

wp-config.php Generator

Constant

Live Value

PHP Syntax

 

DB_NAME

old_database’

define( ‘DB_NAME’, ‘old_database’ );

 

DB_USER

old_user’

define( ‘DB_USER’, ‘old_user’ );

 

DB_PASSWORD

old_password’

define( ‘DB_PASSWORD’, ‘old_password’ );

 

DB_HOST

localhost’

define( ‘DB_HOST’, ‘localhost’ );

 

StatusCopy failed

Database Name

old_database

  

Database User

old_user

  

Database Password

old_password

  

Database Host

localhost

  

 

Save the changes to wp-config.php and upload it back to the server. Your files and database are now officially reunited on the new server! 

If you are hesitant about editing database strings or handling server limits yourself, remember you don’t have to do it alone. You can always turn to DITS.agency specialists for a secure website migration and protect your business from unexpected downtime. 

How to Migrate a WordPress Site to a New Host

The “Magic” Preview (The Hosts File Trick)

Most tutorials will tell you to just flip your DNS switch and “hope” everything works out. That is a great way to end up with a broken site for half the day. Professionals don’t rely on luck; we use a “hosts file” trick to preview the site on the new server before the rest of the world sees it.

Think of this as a private window. You are essentially telling your own computer to look at the new server’s IP address while everyone else is still seeing the old, live site. To do this, you just need to grab your new server’s IP address from your hosting dashboard. On Windows, you open your hosts  file in your System32 folder as an Administrator, and on Mac or Linux, you just run a quick terminal command. You add one simple line at the bottom: your new IP address followed by your domain name. Once you save that, your browser will load the site directly from the new host. You can click every button, check your forms, and verify that your database is connected – all without a single visitor knowing you’re tinkering under the hood.

Pro Tip: If your site is currently behind Cloudflare, this trick won’t work automatically because your browser is looking at Cloudflare’s servers, not your hosting IP. To make this work, you need to turn off Cloudflare’s “Orange Cloud” proxy (set it to “DNS Only” or “Grey Cloud”) temporarily. This bypasses their servers so you can test your actual origin server directly. Most generic guides miss this entirely, but it is the only way to guarantee a zero-downtime launch.

Flipping the Switch (Going Live)

Once you’ve confirmed everything is working in your private preview, it’s time to move the public traffic. Before you touch anything, there is a secret pro move that makes the transition almost invisible: lower your TTL (Time To Live).

Think of TTL as the “refresh rate” for the internet. By default, many domains have a TTL of 24 hours, meaning if you change your site’s location, some parts of the world might not see the update for an entire day. About an hour before you move, go into your DNS settings and drop that number down to 300 seconds (which is just five minutes). This tells every internet provider on the planet, “Check the location of this site every five minutes.”

When you’re ready, you have two ways to flip the switch. If you are just changing the hosting server, you update your “A Record” to point to your new server IP. If you are moving your entire DNS management (for example, if your new host provides its own DNS), you update your “Nameservers” at your domain registrar. After that, just watch the magic happen. You can use a tool like DNSChecker.org to see the update spreading across the globe in real-time. It’s like watching a wave move across a map. Just keep that old hosting account active for about 48 hours – it’s your safety net in case a tiny bit of traffic gets stuck in an old server’s cache.

How to Migrate a WordPress Site to a New Host

Phase 3: Post-Migration Actions & Testing

At this stage, your files and database are securely uploaded to the new server. However, your work isn’t quite finished. If you skip this phase, you risk showing your visitors a broken website or, worse, pointing them back to your old server without even realizing it.

Follow these steps to safely test, launch, and finalize your WordPress site on the new host.

1. Test the Website Before Changing DNS Records

Never point your live domain to a new server blindly. You should always test if the site works perfectly on the new hosting environment first.

Since your domain (yourdomain.com) still points to the old server, you can trick your local computer into viewing the new server by editing your local hosts file.

  • For Windows: Open Notepad as an Administrator and open C:\Windows\System32\drivers\etc\hosts.
  • For Mac/Linux: Open Terminal and type sudo nano /etc/hosts.
  • The Edit: Add a line at the bottom containing your new server’s IP address followed by your domain name:
    192.0.2.1 yourdomain.com
  • The Test: Save the file and open your domain in an Incognito browser window. Your computer will bypass global DNS and load the site directly from the new server. Check your pages, click links, and ensure images load correctly.

(Once you verify everything is working, remember to delete that line from your hosts file!)

2. Update Your DNS Records (The Switch)

Once you are 100% confident that the site operates smoothly on the new host, it is time to direct global traffic to it. To do this, you need to update your domain’s DNS records to point to the IP address of the new server. 

  1. Log into the account where you purchased your domain name (e.g., Namecheap, GoDaddy, Google Domains).
  2. Find the DNS Management section for your domain. 
  3. Locate the existing A record for your domain (and any relevant subdomains) and replace the old server IP address with the IP address of your new hosting server. 
  4. Save your changes.

Understanding DNS Propagation: DNS changes do not happen instantly. It takes anywhere from a few minutes to 48 hours for DNS servers around the world to recognize the updated records. This is called DNS Propagation. During this temporary window, some visitors will still see the old site, while others will see the new one.

3. Reset Your Permalinks Structure

One of the most common post-migration bugs is clicking a blog post link and getting a 404 Not Found error, even though the homepage works perfectly. This happens because the WordPress redirect file (.htaccess) needs to be regenerated for the new server environment.

Fixing this takes exactly 15 seconds:

  1. Log into your new WordPress admin dashboard.
  2. Navigate to Settings > Permalinks in the left-hand sidebar.
  3. Scroll down to the bottom and click the Save Changes button.
  4. Click it a second time. (This forces WordPress to flush its cache and overwrite the hidden server .htaccess file completely).

4. Clear Caches and Re-Install SSL

  • SSL Certificate: Double-check that your new host has active SSL configuration. Most managed platforms generate a free Let’s Encrypt certificate automatically. If they don’t, manually trigger the SSL generation in your new panel so your site doesn’t show an “Insecure Connection” warning.
  • Caching Plugins: If you use caching plugins like WP Rocket, LiteSpeed Cache, or W3 Total Cache, clear all caches immediately to clean up old server paths.
How to Migrate a WordPress Site to a New Host

H2: Common WordPress Migration Errors & How to Fix Them

Even pros run into occasional snags. If something goes wrong, don’t panic – here are the quick fixes for the most common migration errors:

 

Error

Root Cause

How to Fix It

Error Establishing a Database Connection

Incorrect credentials inside your configuration settings.

Open wp-config.php via FTP. Double-check that DB_NAME, DB_USER, DB_PASSWORD, and DB_HOST exactly match the database parameters you generated on your new host.

500 Internal Server Error

Corrupted server rules or plugin conflicts.

The most common culprit is a corrupted .htaccess file. Rename your current file to .htaccess_old via FTP and perform the Permalinks Reset step outlined above to build a fresh one.

Missing Images or White Screen (WSOD)

File permissions error or transfer interruption.

Ensure your folder permissions are set to 755 and files are set to 644 using FileZilla. If individual images are missing, re-upload the wp-content/uploads/ directory.

 

Conclusion & Final Best Practice

Once your site is running flawlessly on the new server, keep your old hosting account active for at least 72 hours. This guarantees that any lingering traffic caught in the DNS propagation window will still land on your old live site without experiencing an outage. Only delete your old server files and close your billing account once your analytics show 100% of the incoming traffic is hitting the new IP address.

Skip the Technical Hassle  –  Move with DITS

Why spend hours troubleshooting database connections and waiting for DNS propagation when you can have a team of certified professionals handle it?

At DITS.agency, we specialized in seamless server migrations. We don’t just move your files; we optimize your new server configuration, secure your databases, and perform a rigorous post-migration QA to protect your SEO traffic.

Contact DITS.agency Specialists Now and transition to your new hosting with total peace of mind.

How to Migrate a WordPress Site to a New Host

FAQ: Why Migration Matters for Your SEO

Will I lose my Google rankings when moving?

If done correctly with zero downtime, your rankings shouldn’t drop. However, if your site stays offline for hours or you introduce hundreds of 404 errors, Google will penalize you. That’s why the “Hosts File” testing method we used earlier is your best insurance policy.

Can I migrate my WordPress site for free?

Absolutely. Manual migration (SFTP + phpMyAdmin) is free, and there are excellent free plugins like All-in-One WP Migration. You only need to pay for your new hosting plan.

How long does the actual DNS propagation take?

It can be instant, but it’s safest to allow 24–48 hours for global propagation. During this time, some visitors might see the old site, and some will see the new one – which is why keeping your old hosting active is non-negotiable.