A staging site is an identical testing ground for your main website. Without a staging site, you’re walking in blind to tweak your site, hoping that it comes out okay.
Building a staging site before you go live helps you catch errors. You’ll also get to see other minor faults you might overlook without having to shut your website down.
If you read on, we’ll show you how to create your staging site from scratch using two main methods:
- The WP Staging plugin
- The SPanel
Creating a Staging Site Using WP Staging Plugin
The WP staging plugin creates a clone website with a copy of your database on a subfolder of the central WordPress installation on your hosting server.
You might install WordPress locally on your computer to test changes. But, it may pose compatibility issues if it works on the localhost but not on a live server.
Since ScalaHosting offers a managed WordPress service, you can create something basic to tweak around on the same server configuration as your website.
Here’s how to create a staging site with WP Staging.
Install WP Staging on your WordPress
The first thing to do is install and activate the WordPress Staging plugin if you haven’t already. The steps below will take you through it.
1. Go to Plugins on your WordPress Dashboard.
2. Click Add New.
3. Go to the search box on the top right of the page and type in “WP Staging.”
4. Once you find WP Staging, click on Install Now.
5. Hit the Activate button.
Run WP Staging plugin on WordPress
The following steps will teach you how to begin the cloning process.
6. You’ll see WP Staging Pro features on the next page. Click “Skip – Start Cloning” at the bottom to begin the cloning process.
- Next, Click on Create new staging site.
8. In the following step, name your new staging site and hit the Start Cloning button.
Depending on the size of your website’s database, the cloning process might take a while.
- After cloning, click Open staging site (login with your admin credentials) at the bottom of the page.
10. The following page will deny you access. Login with your Username and Password to gain access.
11. Type in your login details appropriately, and hit the Login button as shown below to access your cloned site.
Once you’re in, you’re good to go. Your new staging site is a perfect replica of your main site, but for a few differences like the unique URL and orange-colored tab at the top.
The second way to create a staging site is manually. You might find it difficult to manually create a clone site if you have little to zero knowledge about programming, databases, and working with the phpMyAdmin. A lot could go wrong, and you might end up with a crashed site.
We recommend using a WP staging plugin to clone your site if you’re not tech-savvy or are entirely new to this. Nevertheless, if you’re sure you can, read on to know how to create a staging site on SPanel.
Creating a Staging Site on SPanel
Manually creating a staging site on SPanel will let you experiment and dive deeper into custom codes and tweaks. But, you’ll need a subfolder to create your clone site, so you don’t have incompatibility issues later on. We also advise that you have a recent backup of your site that users can access if the main one encounters some problems along the way.
Follow these next steps to learn how to create a staging site on ScalaHosting.
Create a New FTP Account
- On the Dashboard, scroll to Files and select FTP accounts.
- Create a New FTP Account. Be sure to check that the document root is the same as your subdomain.
- Click Create Account.
4. Go to the Files section of your dashboard and Generate a Backup of your site’s database and files.
Import and Export WordPress Folders with FileZilla
For the next step, we recommend downloading FileZilla if you haven’t already. FileZilla is an FTP client that lets you mediate between an online server and your local computer files.
- Launch FileZilla. You’ll see two panels. The “Local site” panel on the left represents your local computer, and the “Remote site” panel on the right is for your website’s files and folders.
- Connect to your host’s server. Enter the FTP credentials you created in Step 6 above and hit QuickConnect.
Though not always, but if you encounter this error, please reach out to us. We’ll walk you through it and help you fix any technical errors for free.
Also, check that you set up FileZilla correctly, and filled in the proper FTP credentials for the host, as it’s usually the cause of this error.
Once you connect to your domain server, some folders will populate on your FTP client’s right panel (Remote site).
Click on the public_html folder to have access to your WordPress website’s files.
- Export these WordPress file folders to your new staging site:
Now, export your WordPress database to the new staging site.
Here’s how to do it:
- Go to phpMyAdmin
- Open the wp-config.php file, and find the name of the database you want to export as an .sql file.
You can also install a dedicated plugin like WP Migrate DB to automatically update the file paths and point to the staging site if you can’t access phpMyAdmin. To do this, make sure you use the same directory path and URL as when you created your subdomain. And you’re set to export the database.
- Head on to Databases. Click on MySQL Database to create a new database for the staging site and import all your data. Hit the Create Database button.
- Click on phpMyAdmin to find the new database. When you find it, click Import.
- Now that you’re all set, edit “wp-config.php to point to the just-created database.
- Login to your staging site to restrict access. To do this, install and activate Restricted Site Access, and do these steps.
Settings > Reading > Restrict site access to visitors who are logged in or allowed by IP address.
A staging site is excellent for testing out new themes and code modifications for your website. It also allows you to continually improve your website behind the scenes while the main site is up and running.
Since you can reach your main website and the staging site on the same domain, the cloned site’s permalinks are often disabled when using WP staging.
To be sure, check to see that the website you’re working on has “STAGING – [your website domain name]” on the admin bar at the top.