Refresh or recreate a WordPress staging environment with WP Manager

Procédure

To refresh a WordPress staging site from your live site, delete the old staging site in WP Manager, then clone your live site again to the same subdomain by checking the box “Overwrite if the folder already exists”. The same method is used to recreate a staging site you have deleted. This help article applies to staging sites created with the WP Manager cloning tool on shared LWS hosting.

What you lose when refreshing the staging site

Refreshing the staging site means replacing it with a fresh copy of your live site. All work done in the staging site since it was created disappears: posts and pages, WordPress settings, user accounts, plugins, themes, and added or modified media. Deletion removes the staging site database and the contents of its wp-content folder, and the new clone, with the “Overwrite if the folder already exists” option, replaces what remains in the subdomain folder.

Refresh the staging site from the live site

  1. Back up the staging site if you want to keep a record of it

    In WP Manager, click MANAGE on the line for your staging site. Open the IMPORT/EXPORT tab, then the Local Files sub-tab. In the Export a backup block, click Download the backup (.zip) to save a complete backup of the test site to your computer.

    If you do not need to keep anything from the staging site, go straight to the next step.

  2. Delete the old staging site

    Still in the staging site details, check under its name that the displayed address is indeed the test subdomain address (for example https://preprod.example.com/) and not your live site address. Open the ESSENTIAL tab, scroll all the way down to the Delete installation block, then click DELETE.

    Refresh or recreate a WordPress staging environment with WP Manager
  3. Confirm deletion

    A Delete installation window opens. Type the word Delete in the field provided, then click CONFIRM DELETION.

    Refresh or recreate a WordPress staging environment with WP Manager

    You are returned to the site list: the staging site no longer appears and its database is deleted. Its subdomain and folder, however, remain in place: keep them, the new clone will be installed there.

  4. Start cloning your live site

    In the WP Manager list, click MANAGE this time on the line for your live site. Open the IMPORT/EXPORT tab, stay on the Clone sub-tab, then click CLONE THE SITE.

    Refresh or recreate a WordPress staging environment with WP Manager
  5. Choose the staging subdomain and options

    In the Clone WordPress installation window:

    • in Destination domain, choose your staging subdomain;
    • in WordPress site name, give it a name that distinguishes it from your live site (for example “Staging”);
    • check Disable indexing (SEO), so search engines do not index this test site;
    • check Overwrite if the folder already exists: the subdomain folder still exists after deletion, and the clone must be able to replace it.
  6. Create the new staging site

    Click CLONE THE SITE at the bottom of the window. Wait while the files and database are copied, without closing or refreshing the page.

Check that everything works

The staging site reappears in the WP Manager list with its subdomain address. Open this address in your browser: you should find the current content of your live site there. To log in to its administration area, click MANAGE on its line, then Admin Login.

Recreate a staging site that has already been deleted

If you deleted your staging site and want to recreate it, follow steps 4 to 6 above. The old staging subdomain and folder are still there: choose that subdomain as the destination and check “Overwrite if the folder already exists”. You can also create another subdomain directly from the cloning window, using the + Create button.

If you no longer want any staging site at all, remove what remains after deletion:

  • the subdomain, in Domain Management > Subdomains: click the red trash icon on its line, then Confirm (deletion takes effect within 1 to 24 hours, while DNS propagation occurs);
  • the subdomain folder (for example /htdocs/preprod.example.com), which is not deleted with the subdomain: remove it with the LWS Panel file manager.

Frequently asked questions

Recreating my staging site fails: what should I check?

First check, in the cloning window, that the “Overwrite if the folder already exists” box is checked: without it, the clone cannot be installed in the folder left in place. Then check that your hosting has enough free disk space for a complete copy of your site, files and database. If the error persists, open a support request from your customer area, indicating the address of your live site, the destination subdomain, the exact error message, and the time of the attempt.

What remains after deleting a staging site?

Deletion in WP Manager removes the WordPress files, the contents of wp-content, and the staging site database. The subdomain remains declared, and its folder remains on the hosting with any files you may have added yourself.

Does my live site appear twice on Google because of the staging site?

Not if you check “Disable indexing (SEO)” at each clone: this option prevents search engines from indexing the staging site. Remember to check it again with each refresh, since the staging site is recreated.

Related articles

help.lws.net/a/8030
Was this article helpful?

Yes

No

Read 5 times

Thank you! Feel free to ask questions about our documentation if you would like more information, and help us improve it.

Similar articles

A question about this article?

Ask the LWS team and the community. Answers are published after moderation.

Ask the LWS team and its community a question

GDPR: Controller: LWS-Ligne Web Services. Purpose: moderation and public publication of your question, possible notification of an answer. Legal basis: consent (Art. 6(1)(a) GDPR). Email retention: 90 days after notification, 12 months maximum without an answer. To exercise your rights, see the GDPR section of our Terms and Conditions.