It’s a good idea to have a clone of your entire website to be able to test as much possible on your WordPress site before doing any real changes on your production site.
WP Staging allows you to create a site for testing purposes and is your specialized tool to copy a staging site and all of its data to the production site.
Even better, it also allows you to create a clone of an already existing staging site and allows you to copy this cloned site to the parent clone as well.
This allows you to create a development and staging website beside the production system, a structure which is widely common and used by professional developers all over the world:
This development structure is very helpful if you want to test all the steps from cloning to pushing and to make sure there are no errors in that process chain before you repeat the steps on your production website.
How to create a dev > staging > production environment
- Go to your production website and clone it. Name this site “staging”.
- Add an empty file named
.wp-staging-cloneableinto the root directory of “staging”. Otherwise, you can not clone the staging site!
- Log in to your staging website and clone it. Name the clone “dev”
How to push the dev site to the staging site
Login to the
staging site > wp staging > sites and PUSH the listed dev site to the staging site.
How to push the staging site to the production site
Login to the
production site > wp staging > sites and PUSH the listed staging site to the production site
How to clone a staging site
If you like to clone a staging site created with WP Staging you first need to tell WP Staging that the cloned staging site is allowed to be cloned.
You can follow one of the two options to do so:
- Create an empty file named
.wp-staging-cloneableand add it into the root folder of your staging site by using a file manager plugin or FTP.
Alternatively, you can create a little modification in the database table
wpstg(int)_options of the staging site:
- Open PHPMyAdmin and look for the option_name
wpstg_is_staging_site. through the table
wpstg(int)_optionswhich belongs to the staging site.
- Set this value to
falseor delete it at all:
As always, please make a full database backup before you are going that route and changing anything in the database!
If you’ve made any of these changes you can start creating a clone of the staging site by going to
Staging Site > wp-admin > WP Staging > Start
So for instance, you can name your first staging site “Staging”. Then you go to Staging > wp-admin > wp staging > Start and name the clone of the clone “Development”.
Now you can work on the “Development” site. While you are working on it you can push the content to the site “Staging”. You need to do this from Staging > wp-admin > wp staging
When you go to your production site and open WP Staging you can push from there the site “Staging” to the production site.