Hardware FixRecommendedDevice not working? Your driver may be the problemCheck updates for common hardware issues.Fix DriversOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PC×
Skip to content
VGSources
Blog

How to Transfer the wp-content Folder to a New WordPress Host

A complete, step-by-step guide to moving wp-content, the WordPress database and configuration to a new host, with secure transfer instructions and fixes for common migration errors.
Length12 min Posted Quest giverVGSources Team
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

You can transfer wp-content to a new WordPress host, but the folder alone is not a complete migration. It carries your themes, plugins and uploads; your posts, pages, comments, users and settings remain in the WordPress database. A reliable move therefore includes a file backup, a database export, the correct wp-config.php values, and testing before DNS is changed. The sequence below preserves the old site and gives you a rollback path.

What a wp-content transfer actually moves

WordPress describes wp-content as the user-owned area of an installation. It normally contains three directories:

As an Amazon Associate I earn from qualifying purchases.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • plugins — installed plugin code and, for some plugins, locally stored files.
  • themes — your active theme and any other installed themes.
  • uploads — media files arranged in year-and-month folders, unless a plugin or a custom configuration uses another structure.

The folder does not contain the records that make up your site’s content. Posts, pages, comments, categories, menus, widget settings, plugin options, user accounts and most WordPress settings are stored in MySQL or MariaDB. Those records must be exported and imported separately. The root-level wp-config.php file is separate again; it contains the credentials and constants WordPress needs to connect to the database and locate content.

WordPress’s migration guidance confirms that you can move an installation without reinstalling WordPress, provided that both the files and database are moved: WordPress Migrating documentation. Its file-backup guidance specifically identifies wp-config.php and wp-content as important files to preserve: Backing Up Your WordPress Files.

#1 Best Overall
Seagate Portable 1TB External Hard Drive HDD – USB 3.0 for PC, Mac, PlayStation, & Xbox, 1-Year Rescue Service (STGX1000400) , Black
  • Easily store and access 1TB to content on the go with the Seagate Portable Drive, a USB external hard drive.Specific uses: Personal
  • Designed to work with Windows or Mac computers, this external hard drive makes backup a snap just drag and drop. Reformatting may be required for Mac
  • To get set up, connect the portable hard drive to a computer for automatic recognition no software required
  • This USB drive provides plug and play simplicity with the included 18 inch USB 3.0 cable
  • The available storage capacity may vary.
Item What it restores What happens if it is missing
wp-content Themes, plugins and uploaded media The database may load, but the site can show missing themes, plugin errors or broken media.
Database export Posts, pages, comments, users, settings, menus and plugin data A fresh or empty site appears even though the files are present.
wp-config.php values Database connection, table prefix and optional path constants “Error establishing a database connection,” wrong tables, or an inaccessible custom content directory.
WordPress core The application files that execute WordPress The server has no working core, or the core version is incompatible with the transferred extensions.

Prepare the move before downloading anything

Choose a maintenance window and make a written inventory. You need administrator access to the old hosting account, SFTP or another file-transfer method, database export/import access, and the destination host’s document-root and database details. Keep the old site online and untouched until the replacement has passed testing.

  • Confirm the old WordPress version, PHP version and database engine, then check that the destination supports versions compatible with your themes and plugins.
  • Identify the actual document root. Depending on the host, it may be a directory such as public_html, www or a site-specific path.
  • Record whether the site uses a staging URL, a subdirectory, a multisite network or a nonstandard content directory.
  • Plan where the backup will be stored. Keep one copy away from both hosting accounts; an encrypted external drive is suitable for a second copy.

1. Make a complete, verifiable backup

Download the files

At minimum, retain the complete wp-content directory and the old wp-config.php. A full file archive is safer because root-level files, web-server rules and custom drop-ins may be needed during recovery. Include hidden files such as .htaccess when your transfer method allows it. Do not edit or delete the old copy while creating the backup.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Open the downloaded archive and verify that it contains the expected plugins, themes and uploads directories. Check several media files and the active theme directory rather than relying only on the archive’s file count.

Export the database

Use the old host’s database tool, command line or control panel to export the database named in wp-config.php. A typical export is an SQL file. Include all tables that use the site’s table prefix, not just the tables with names beginning with the default wp_ prefix; a customized prefix is common and may be defined in the configuration.

The WordPress database-backup guidance explains the purpose and handling of this export: Backing Up Your Database. Protect the SQL file as confidential data because it can contain user information, site settings and hashed credentials. Store it outside a publicly served directory and do not leave a downloadable copy in the old site’s web root.

Check that the backup can be used

Record the archive names, database name, export date and the WordPress version beside the backup set. If possible, inspect the SQL file header and confirm that its size is plausible for the site. A zero-byte or unexpectedly tiny export is not a usable backup. Keep the files together so that a database from one point in time is not accidentally combined with uploads from another.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

2. Record wp-config.php and custom paths

Open a copy of the old wp-config.php; never publish the original contents. Note these values:

Rank #2
Seagate Portable 4TB External Hard Drive HDD – USB 3.0, 1-Year Rescue | Everyday HDD storage. Plug-and-play backup. Windows & macOS. Adobe CC trial included. 1-Year Warranty
  • Easily store and access 4TB of content on the go with the Seagate Portable Drive, a USB external hard drive.Specific uses: Personal
  • Designed to work with Windows or Mac computers, this external hard drive makes backup a snap just drag and drop
  • To get set up, connect the portable hard drive to a computer for automatic recognition no software required
  • This USB drive provides plug and play simplicity with the included 18 inch USB 3.0 cable
  • The available storage capacity may vary.
  • DB_NAME, DB_USER, DB_PASSWORD and DB_HOST.
  • $table_prefix, including capitalization and any non-default value.
  • WP_CONTENT_DIR and WP_CONTENT_URL, if present.
  • Any DISABLE_WP_CRON, multisite, cache, reverse-proxy or debugging constants that the new environment must reproduce.

WordPress permits the content directory to live outside the normal application directory when WP_CONTENT_DIR and, where needed, WP_CONTENT_URL are defined. The constants are documented in the wp-config.php reference. If the old site uses them, decide whether to preserve the same absolute path or deliberately move the directory and update both the filesystem and URL definitions.

3. Transfer wp-content securely

Use SFTP when the host provides it. Learn WordPress recommends SFTP over FTP because SFTP encrypts the password while it is sent: Migrate, Copy, Or Clone A Site. Ask the host for the SFTP hostname, port, username, authentication method and starting directory.

  1. Connect to the old host with an SFTP client and locate the directory containing wp-admin, wp-includes, wp-content and wp-config.php.
  2. Download the entire wp-content directory, not just the active theme or the visible media folders. Preserve capitalization, nested directories and symbolic-link behavior where the host supports it.
  3. Wait for the transfer to finish and review the client’s failed-transfer queue. Retry failures before disconnecting.
  4. Keep the downloaded copy unchanged. It is your rollback source if the new host has a permissions or compatibility problem.

FTP can transfer the same files, but it does not provide the password protection of SFTP. If SFTP is unavailable, use the host’s encrypted file-manager download or a host-supported secure archive workflow rather than transmitting credentials over an unencrypted connection.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

4. Prepare the new WordPress installation

Create the destination database and a database user with the permissions WordPress requires. Write down the new database name, username, password, host and table prefix. These values often differ from the old host even when the site’s domain remains unchanged.

Install a compatible WordPress core in the new document root, or copy the old core files as part of a complete migration. A clean core installation supplies wp-admin and wp-includes; it does not supply your old content. Do not visit the installer and create a new site using the same domain before importing the old database unless you understand how to remove the temporary tables.

Before replacing the starter content directory, make a backup of the new host’s original wp-content. It may contain host-specific drop-ins or a default theme that is useful for recovery. Confirm that the document root you selected is the one actually served by the domain or temporary hostname.

5. Upload and place the old wp-content directory

  1. Connect to the new host with SFTP and open the destination WordPress directory.
  2. Rename the new, empty wp-content to something such as wp-content-new-backup, or preserve it in a separate archive.
  3. Upload the old wp-content directory so that its final path is exactly the path expected by WordPress. The normal layout is /your-document-root/wp-content/, containing plugins, themes and uploads.
  4. If you are merging rather than replacing, copy the old directories carefully and resolve conflicts in favor of the backed-up old site, while retaining any destination-specific files you intentionally need.
  5. Compare directory names and a sample of file sizes with the download. An extra nesting level such as wp-content/wp-content/uploads will make every media URL fail.

Do not change ownership or permissions to arbitrary values copied from the old host. Hosting platforms run PHP under different users and groups. Apply the destination host’s documented defaults after the upload.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #3
Sale
WD 2TB Elements Portable External Hard Drive for Windows, USB 3.2 Gen 1/USB 3.0 for PC & Mac, Plug and Play Ready - WDBU6Y0020BBK-WESN
  • High capacity in a small enclosure – The small, lightweight design offers up to 6TB* capacity, making WD Elements portable hard drives the ideal companion for consumers on the go.
  • Plug-and-play expandability
  • Vast capacities up to 6TB[1] to store your photos, videos, music, important documents and more
  • SuperSpeed USB 3.2 Gen 1 (5Gbps)

6. Import the database and update configuration

Import the SQL file

Use the destination host’s database manager or command line to import the SQL export into the new database. Select the correct database before importing. If the host imposes an upload-size or execution-time limit, use its command-line importer or split the export only with a method that preserves SQL order and encoding.

After import, check that the expected tables exist and that their prefix matches the $table_prefix you recorded. A successful upload of an SQL file into the wrong database can look like a successful migration while leaving WordPress connected to empty tables.

Edit wp-config.php

Copy the old configuration values into the new installation, then replace the connection values with those supplied by the destination host:

  • Set DB_NAME, DB_USER, DB_PASSWORD and DB_HOST to the new database details.
  • Set $table_prefix to the prefix used by the imported tables.
  • Reproduce required constants such as WP_CONTENT_DIR, WP_CONTENT_URL, multisite definitions and cache settings.
  • Preserve security keys and salts unless you intentionally want to invalidate all logged-in sessions.

Save the file as plain text with the PHP opening tag intact. A missing semicolon, an accidental smart quote or whitespace before <?php can produce a blank page or a server error.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Handle a domain or path change safely

If the domain, protocol or installation path changes, WordPress still has the old addresses stored in the database. Update the home and siteurl options to the new canonical URL. You can do this through a controlled database method or a migration utility, but do not run a blind text replacement across the SQL file.

Many WordPress options and plugin settings are serialized. In serialized data, changing the number of characters in a URL without updating the stored length corrupts the value. Use a migration-safe search-and-replace method that understands serialized data, then inspect content, widgets and plugin settings for absolute URLs that require separate treatment. If only the host changes and the path does not, still check redirects, canonical tags and media URLs.

7. Set permissions and protect temporary files

Apply the new host’s recommended ownership and permissions to the uploaded files and directories. The exact values vary by operating system, PHP handler and hosting model, so the host’s documented defaults take precedence over generic recipes. Incorrect ownership commonly causes failed media uploads, plugin update errors, inability to write cache files or a blank page when a required file cannot be read.

Rank #4
YOTUO 500GB External Hard Drive, Portable Storage Expansion HDD, USB 3.0 & USB-C for PC, Mac, Desktop, Laptop, Smartphone, PS4, Xbox One, Xbox 360, Office & Game Black
  • 【Versatile Storage Expansion – For Gaming, Work & Everyday Use】 Running out of space on your PS5 or Xbox Series X/S? This external hard drive lets you store and play PS4 / Xbox One games directly, instantly freeing up your console’s internal storage for next‑gen titles. At the same time, it handles work file backups, media libraries, and cross‑device data transfers with ease. One drive, all your needs. *(Note: PS5 / Xbox Series X|S games cannot be run or stored directly from the external hard drive. However, by offloading your PS4 / Xbox One games, you can free up valuable space for newer titles.)*
  • 【Patented Silicone Sleeve – Data Protection You Can Count On】 Worried about drops? We’ve got you covered. The patented built‑in silicone sleeve acts like a shock‑absorbing armor, cushioning your drive against bumps and falls. Whether it’s important work documents, precious family photos, or hard‑earned game saves, your data deserves this level of protection.
  • 【Plug & Play, Compatible with Computers & Consoles】 No complicated setup—just plug in and go. Works seamlessly with Windows, Mac, and Linux computers, as well as PS4, PS5, Xbox One, and Xbox Series X/S. Process files at the office, back up data at home, or enjoy gaming in your downtime—one drive handles all your devices, simply and hassle‑free.
  • 【USB 3.0 Ultra‑Fast Transfer – No More Waiting】 Tired of watching progress bars crawl? With USB 3.0 speeds up to 5Gbps, large files transfer in seconds. Whether you’re moving work documents, transferring hundreds of gigs of games, or backing up a year’s worth of photos, you get more done in less time.
  • 【Sleek, Lightweight, and Ready to Go】 Weighing just 0.16 kg—lighter than a can of soda—this compact drive features a stylish mirror‑and‑frosted finish. Toss it in your bag and go, whether you’re heading to the office, visiting a friend for a gaming session, or giving a presentation on the road.

Remove temporary SQL files, compressed archives and diagnostic copies from any publicly accessible directory after the migration. Keep private backups offline or in access-controlled storage. Restrict SFTP accounts to the site where possible, and remove temporary credentials when the work is finished.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

8. Test the new site before changing DNS

Use the host’s temporary URL, hosts-file override or staging domain so that the public domain still points to the old server while you test. Work through the following checks:

  • Load the front page and several internal posts or pages. Confirm that the expected theme is active and that layout assets load.
  • Sign in to /wp-admin. Open the Plugins, Themes, Media and Settings screens and look for warnings.
  • Open media-library items and several front-end image URLs. A 404 usually indicates an incorrect upload path, missing files or a URL mismatch.
  • Submit every important form, including contact, login, password-reset and checkout forms if the site uses them. Verify mail delivery separately because the new host may impose different SMTP or PHP-mail rules.
  • Test plugin features that depend on scheduled events, background processing, webhooks, cron, object caches or external APIs.
  • Visit Settings, Permalinks and save the existing structure once to regenerate rewrite rules. Then test category, tag, author, search and pagination URLs.
  • Check user accounts, comments, menus, widgets, custom post types and any multilingual or membership functions that store data in the database.

Watch the PHP and web-server error logs while performing these tests. A plugin that worked under the old PHP version may fail under the new one; disable the offending plugin from the Plugins screen or, if the dashboard is unavailable, rename its directory under wp-content/plugins to regain access.

9. Change DNS and keep a rollback window

If the domain is moving, lower its DNS TTL before the final switch when your DNS provider allows it. Do this early enough for the previous long TTL to expire. Change the relevant A, AAAA or CNAME records only after the temporary-host tests pass.

DNS caches do not all update simultaneously. During propagation, some visitors may reach the old host and others the new one. Keep the old site online and do not accept conflicting content on both servers. If the site receives orders, comments or user registrations, place it in maintenance mode or schedule the cutover during a quiet period so that no database writes are lost.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

After the record change, test from more than one network and resolve the domain to confirm that traffic reaches the new address. Retain the old files and database until the new site has remained stable through normal traffic, scheduled jobs and at least one backup cycle.

Folder-only and database-only moves: what they can and cannot do

Copying only wp-content preserves the visual and functional files but cannot recreate database-backed content. The new installation will show a fresh site, an empty site or database-connection errors unless the old database is also imported and configured.

Moving only the database has the opposite problem: WordPress can see posts and settings, but the active theme, plugins and uploaded media are absent. The result is often a broken layout, missing images and fatal errors from unavailable extensions. Treat the files and database as one matched backup set.

Common failure symptoms and targeted fixes

“Error establishing a database connection”

Recheck DB_NAME, DB_USER, DB_PASSWORD and DB_HOST against the destination host’s panel. Confirm that the user is assigned to the imported database and that the database server does not require a socket path or a nonstandard port.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The site loads a new installation instead of the old site

The old SQL export was probably not imported, was imported into another database, or wp-config.php points to the wrong database or table prefix. Inspect the tables and the wp_options values in the database actually used by the new site.

Images return 404 errors

Check that uploads is in the expected location, that its permissions allow the web server to read files, and that the stored site URL and content URL use the new domain and protocol. Confirm that no extra wp-content directory was created during upload.

Plugins or themes disappear

Verify that the old directories were transferred completely and that the dashboard is looking at the same content path. If WP_CONTENT_DIR or WP_CONTENT_URL was defined on the old host, reproduce compatible definitions or move the files to the path those constants specify.

Permalinks show 404 errors

Save the existing permalink structure in the dashboard to regenerate rewrite rules, then confirm that the new host supports the required Apache or Nginx rewrite configuration. A missing or unwritable .htaccess can affect Apache sites.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

A blank page or HTTP 500 error appears

Inspect PHP error logs, check the PHP-version compatibility of the active theme and plugins, and temporarily deactivate the suspected extension. Renaming its directory under wp-content/plugins is a recovery option when the dashboard cannot be opened. Restore the backed-up directory if a transfer was incomplete.

When the migration is complete

Once DNS has settled and the site is functioning normally, create a fresh backup on the new host, verify that scheduled backups actually run, and remove obsolete transfer archives and temporary accounts. Keep the original backup set until you have a tested recovery copy from the new environment. The essential rule remains simple: wp-content is indispensable, but it is only one part of a WordPress migration; the database and configuration must travel with it.

Quick Recap

Bestseller No. 1
Seagate Portable 1TB External Hard Drive HDD – USB 3.0 for PC, Mac, PlayStation, & Xbox, 1-Year Rescue Service (STGX1000400) , Black
Seagate Portable 1TB External Hard Drive HDD – USB 3.0 for PC, Mac, PlayStation, & Xbox, 1-Year Rescue Service (STGX1000400) , Black
This USB drive provides plug and play simplicity with the included 18 inch USB 3.0 cable; The available storage capacity may vary.
$119.80
Bestseller No. 2
Seagate Portable 4TB External Hard Drive HDD – USB 3.0, 1-Year Rescue | Everyday HDD storage. Plug-and-play backup. Windows & macOS. Adobe CC trial included. 1-Year Warranty
Seagate Portable 4TB External Hard Drive HDD – USB 3.0, 1-Year Rescue | Everyday HDD storage. Plug-and-play backup. Windows & macOS. Adobe CC trial included. 1-Year Warranty
This USB drive provides plug and play simplicity with the included 18 inch USB 3.0 cable; The available storage capacity may vary.
$208.99
SaleBestseller No. 3

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More quests from Patch Notes

  1. How to Set Up a RedM (RDR2) Server in 2026: License Key, txAdmin and server.cfg, Step by StepBlog11min
  2. Best RedM (RDR2) Server Hosting in 2026: Comparing Four Hosts on Slots, Memory and PriceBlog10min
  3. How to Host a Mindustry Server in 2026: server-release.jar, Port 6567 and the Commands That MatterBlog7min
Recommended PC Tool
Recommended PC Tool
Outdated Drivers Are Slowing You DownFree scan - exact matches
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.