Back to Support Hosting Create a Staging Site

Create a Staging Site

Use a staging site to clone your entire WordPress.com site for testing purposes. This guide will show you how to create a staging website on WordPress.com.

This feature is available on sites with the WordPress.com Creator or Entrepreneur plan.

How to Create a Staging Site

A staging site is a great place to test plugin and theme updates or any other changes you plan to make to your live site.

To create a staging site, follow these steps:

  1. Visit your site’s dashboard.
  2. Navigate to Settings → Hosting Configuration (if using Default View) or Hosting → Configuration (if using WP-Admin).
  3. Scroll down to the Staging site section.
  4. Click the “Add staging site” button:
Add a Staging Site button shown.

If you have already created a staging site, you will see a “Manage staging site” button instead:

Manage or delete a staging site via the Hosting Configuration page.

Once you have created your staging site, you can find it under your list of sites and via the Manage staging site button at Settings → Hosting Configuration as explained above.

How Staging Sites Work

The staging site feature copies your existing site to a new site. The new staging site’s address will start with staging followed by four random characters and the site address.

Your newly created staging site is completely decoupled from the original site; any changes to one won’t impact the other.

The staging site will remain active as long as your production site (i.e., your main, live website) has an active plan. The production and staging sites share the same storage allocation, and storage is split 50/50 between the two.

Data Copied to a Staging Site

The following site-specific data is cloned to your staging site:

The following WordPress.com-specific data isn’t copied to your new site because these features are site-specific:

Features of a Staging Site

The staging site works very similarly to the production (live) site. SFTP, SSH, and phpMyAdmin can be accessed in the same way at Settings → Hosting Configuration. You can install plugins, switch themes, and restore backups on the staging site, just like on the live site.

Sync Data Between Staging and Production

📌

This is a beta feature. If you find that something does not work as expected or you would like to share ideas on how to improve this feature, please contact us and share your feedback.

You can synchronize the database and filesystem between the staging environment and the production (live) environment in both directions. The only exception is for sites using WooCommerce — WooCommerce data cannot be synced back to production due to risks in overwriting orders received after the staging site was created.

You must have access to both the production and staging sites in order to sync changes between them. If a user has access to one, but not the other, add them as an admin to both production and staging so they can sync changes.

Below, learn how to Synchronize Production to Staging and Synchronize Staging to Production.

Customize Search Engine Behavior

By default, search engines will be blocked from indexing the staging site. However, this behavior can be overridden with a custom robots.txt file placed in the root folder of your website.

Synchronize Production to Staging

Before you start working with themes or plugins, we recommend making the staging site a fresh copy of the production site. If you would like to refresh your staging site and make it a copy of the production site again, follow these steps:

  1. Visit your staging site’s dashboard.
  2. Navigate to Settings → Hosting Configuration (if using Default View) or Hosting → Configuration (if using WP-Admin).
  3. Scroll down to the Staging site section.
  4. Locate the “Database and file synchronization” section.
  5. Select the “Production to staging” option.
  6. Click the “Synchronize” button.

When the confirmation window appears, proceed by clicking “Synchronize”.

Synchronize Staging to Production

Follow the steps below to synchronize media files, plugins, themes, and/or database content, such as posts, pages, and menus, from your staging site back to your production (live) site.

When you are satisfied with your changes and would like to copy them from staging to production, follow these steps:

  1. Visit your staging site’s dashboard.
  2. Navigate to Settings → Hosting Configuration (if using Default View) or Hosting → Configuration (if using WP-Admin).
  3. Scroll down to the Staging site section.
  4. Locate the “Database and file synchronization” section.
  5. Select the “Staging into production” option.
  6. Select which parts of the staging site you wish to synchronize to your production site:
    • Themes: Choose this option if you added new themes, upgraded existing ones to the new version, or edited theme files. Note that If you change your active theme, you must activate it on the production site manually unless you synchronize the ‘Site Database‘, too.
    • Plugins: Choose this option if you installed new plugins, upgraded existing ones to the new version, or edited plugin files. Note that If you activate or deactivate your plugins, you must do the same on the production site manually unless you synchronize the ‘Site Database‘ too.
    • Media Uploads: Copy all files and directories in the uploads directory. You must also select ‘Site database‘ if you wish for the files to appear as media uploads in WordPress.
    • wp-content Directory: Choose this to synchronize all files and directories in the wp-content directory other than themes, plugins, and uploads.
    • Web Root: Select this to copy all files and directories in the WordPress root, including any non-WordPress files, excluding the wp-content directory.
    • Site Database (SQL): Choose this option if you added or edited posts or pages, uploaded new media, edited site templates using Site Editor, or performed other changes related to data stored in the database. Due to the risk of overwriting orders, this option cannot be enabled on sites with the WooCommerce plugin installed.
  7. Click the “Synchronize” button.
  8. When the confirmation window appears, proceed by clicking “Synchronize”.
The options for syncing staging to production.
Choose the direction of your sync, select which parts of the site you wish to sync, and click the “Synchronize” button.

Please be aware that copying a staging database to a production environment might result in losing existing data on the production site, as the staging data will replace it. WooCommerce data cannot be synced back to production due to risks in overwriting orders received after the staging site was created.

The PHP version in the production environment doesn’t automatically update to match the version you’ve set in staging. To ensure both environments use the same PHP version, you’ll need to manually update the PHP version in production as well. After you’ve finished syncing, you can change the production PHP version using this guide.

Delete a Staging Site

To remove your staging site, follow these steps:

  1. Visit your production site’s dashboard.
  2. Navigate to Settings → Hosting Configuration (if using Default View) or Hosting → Configuration (if using WP-Admin).
  3. Scroll down to the Staging site section.
  4. Click the “Delete staging site” button:
The delete staging site button is highlighted.

Frequently Asked Questions

Who can create a staging site?

A staging site can be created by any administrator on your site. The site owner will always be added as the owner of the staging site, even if the staging site was created by another administrator. 

What happens when I clone a site with WooCommerce enabled?

All WooCommerce data in the database will be cloned to the staging site, which may include customers, products, orders, or any other WooCommerce-related information stored in the database. We will also add the WP_ENVIRONMENT_TYPE=staging constant to the wp-config.php file, which some plugins may use to differentiate production and staging environments.

However, while WooCommerce is active on a site, the database cannot be synced back to production due to risks of overwriting orders received after the staging site was created.

Can I create more than one staging site?

It is currently possible to create only one staging site per production site. You can create unlimited copies of your site via our Copy a Site feature.

Can I customize the staging site URL?

The staging site URL is created automatically by prepending “staging-[random-four-characters]” to the production site name. It’s not possible to edit this address or add a custom domain because a staging site is not intended to be used as a live site. To make a copy of your site intended for public viewing, take the steps in our Copy a Site guide instead.

Was this guide helpful for you?

Not quite what you're looking for? Get Help!

Copied to clipboard!