What Is a Staging Site? How Do You Set One Up?
Developing a website can involve a number of risks. For example, it’s never fun to make changes and realize that your live website has crashed. Fortunately, using a staging site can provide a safer environment for website development and innovation.
In this article, we’ll go over various types of development environments and how they stack up in comparison to staging sites. We’ll also cover several methods you can use to set up your own staging site. Let’s get started!
What is a staging site?
To put it simply, a staging site is a clone of your live website. It enables you to test any changes or major new features that you plan to implement in a secure environment. Developers typically use staging sites to test changes and fix bugs before going to production.
Your staging site is intentionally identical to your live site—same plugins, same settings, same widgets, and so on. The only real difference between your live website and a staging site is that the latter is not live.
Instead, it exists in a sort of sandbox where you can see how your WordPress website would react in everyday scenarios. Anything that happens in the staging environment won’t affect your live website.
Development vs. QA vs. Staging vs. Production Sites
While visitors may only see the finished product, plenty of work goes on behind the scenes of a typical website. In fact, some developers use up to three or four different versions of the same site, in order to test their code before it goes live.
Let’s take a look at the most common types of WordPress testing environments that are used during development:
- Development website. This environment contains all the latest iterations of the code you’re working on. It’s perfect for initial testing of new features.
- Quality Assessment (QA). During the QA process, changes to your website will be tested thoroughly to find any issues that you may have missed while coding. This type of environment is most often used by large companies, since they can’t afford to have bugs pop up on live sites.
- Staging website. A staging website acts as the bridge between the development and live versions of your site. At this point, any remaining errors should be addressed, and the changes should be ready to roll out.
- Production website. This is the live version of your website that users will see. If you’ve been careful throughout the development process, this iteration of your WordPress site should be bug-free and provide a flawless user experience.
It’s worth noting that staging environments aren’t meant to be accessed by the public or by a search engine like Google. If you use your staging site correctly, your live site’s visitors should never have to deal with any issues, such as your WordPress site breaking due to changes in its code.
By now, you know how the website staging process fits into the web development process. However, you may still be wondering if using a staging environment is suitable for your needs. Let’s walk through the pros and cons to help you make an informed decision.
Staging Environment vs. Testing Environment
Both staging environments and testing environments involve putting your website to the test. The difference between the two comes from what is being tested and to what degree.
In a staging environment, your website will exist in its final, most current form. Everything should be up to date; the only factor that should separate your staging site from your live site is the feature(s) that you’re testing.
So, what is staging used for? Staging typically comes at the very end of the web development process, and its goal is to test the website as a whole before changes are published.
A testing environment is for experimenting with smaller, specific changes. Because you’re only testing a portion of code, you don’t need to have every aspect of the website in its completed state. In general, testing comes before staging—a test environment is a place to quickly check on subtle changes as you go.
The Benefits of Using a Staging Site
It doesn’t take much to sell the benefits of a WordPress staging site. They:
- Enable you to produce better websites
- Provide you with the opportunity to catch errors and bugs without putting your site at risk
- Are usually simple to create
- Can be set up locally or online (depending on your preferences)
Having said that, there are some drawbacks to consider as well.
The Drawbacks of a Staging Site
The major drawbacks of using a staging site are:
- It takes longer to update your website (as you need to test changes first).
- Web hosts often charge for a staging site service (although you can always set one up locally).
- Staging sites may not be exact replicas of a live website (caching is not usually enabled on a staging site, for example).
Fortunately, there are some ways to alleviate these potential issues. For instance, all of our hosting plans here at WP Engine include free staging sites. Additionally, our staging sites offer true vagrant environments, which among other things means you’ll have full caching capabilities.
Who Needs a Staging Site?
Ideally, everyone who runs a website needs a staging test site. However, if we’re being practical, staging websites should be used at the very least by anyone who runs a sizable operation.
If you’re comfortable with the knowledge that one of your updates could break your site and alter its functionality, or render it unusable while you fix it, then you probably don’t need a staging site.
However, if your website generates income (directly or indirectly), provides any type of service, or has users that depend on it, creating a staging website is definitely a smart move. There are even different approaches available depending on your preferences, which we’ll discuss below.
How to Create a Staging Site for WordPress
There are three main ways to go about creating a staging website for WordPress. The first is to set up a staging environment with your WordPress host. The second option is to use a WordPress staging plugin. Finally, you can also set up a ‘local’ installation of your website platform – completely separate from your main website – where you can test any changes you want.
In the following sections, we’ll take a look at all three options. Plus, we’ll point you towards some resources to help get you started!
Option 1: Set Up a Staging Test Site Through Your WordPress Host
Not all web hosts offer staging sites as a part of your hosting plan. In that case, you can still create a staging server, but you’ll likely have to pay extra.
If you’re a WP Engine customer, on the other hand, you can access this functionality right on your User Portal by going to Sites > Add Site and naming your new staging site:
After that, you can select a Staging environment and you’re all set! To access your new staging site, you can go to Sites in your User Portal menu:
To access more options for your staging site, you can click the STG icon next to its name. From there, you’ll be taken to a dashboard for that staging site where you can push and pull changes, view data, and access your WordPress administration login page.
Best of all, our staging service enables you to set up full copies of your website in a matter of clicks, and then merge them back with your live installation just as easily. As far as staging goes, it doesn’t get any simpler than that.
Option 2: Using a WordPress Staging Plugin to Create Your Staging Sandbox
If setting up a staging site with your web host is not an option, you can also use a plugin like WP Staging:
This WordPress plugin essentially makes a clone of your existing site, including all of its files and the database. Once it’s cloned, you can access the staging site using a distinct URL, and experiment to your heart’s content without impacting your live site.
Once you’ve installed and activated the WordPress plugin, you can select Start Cloning and it will scan your site for relevant information. Next, you can decide whether you want to copy over all of your site’s database tables and files, or just specific ones.
After making your choices, click on Start Cloning again. You’ll get a real-time readout of the cloning process as it takes place. How long it takes to clone your site will depend on the overall size, but once it’s done you’ll be ready to use your new staging site.
Option 3: Set Up a Local Installation
Both of the previous methods involve setting up online staging sites. Those can be very flexible, and enable multiple people to work on them easily. However, you can also set up a local, offline staging site, which only those with access to your computer will be able to use.
There are several ways to go about creating local WordPress websites. One of the most popular options involves using a tool such as Local:
This is a free application that turns your computer into a simple hosting environment. Once you download the software, you’ll be guided through the steps needed to set up your local development site, starting with its name:
Once you set a name for your site, you’ll need to choose a username and password for your WordPress account. Then, the software handles the rest of the process. You’ll be able to access your site and your WordPress dashboard from the Local interface as soon as the setup process completes.
Should You Create a Staging Site Manually?
Manually creating a staging site is not especially difficult, but it can pose problems, particularly for a WordPress beginner.
Creating a staging site in this way involves multiple steps—making a subdomain and an FTP account, importing your database, and hiding your staging site (since it’s technically still live). A mistake in any of these steps can mean that unpublished features become accessible to the public. Deploying the changes you’ve made in your manual staging site is also more difficult, as modifications can get lost in the transition.
In short, you should only create your staging site manually if you’re confident in your abilities. Otherwise, it’s best to work with professionals, like our team at WP Engine. Regardless of the route you take, be sure to save a recent backup of your website before making any changes.
How to Deploy Changes to Your Live Site
Regardless of which method you use to create your staging site, pushing the changes you make on it over to your live website can be tricky. Fortunately, most of the options we listed above have built-in functionality to help you navigate this step.
If you’re using a staging site provided by your web host, pushing changes to your live site should be pretty simple. For example, with our staging environments, you can use the Copy To and Copy From buttons in your User Portal:
These options enable you to push your staging site to your production site, and vice versa.
If you’re using the WP Staging plugin, you’ll need to check out the premium upgrade if you want to enable updates to your live site:
Once you’ve upgraded the WordPress staging plugin, you’ll need to create backups of both your live and staging sites. Then you can use the plugin’s interface to select the data you want to push to your live site.
Local environments often provide ‘push to live’ options as well. With Local, you can use the Connect feature:
This enables you to use your account login credentials to connect Local to your website’s hosting provider if you’re using WP Engine or Flywheel. Once you complete that step, you can use the Connect icon to push and pull updates between your website and your local environment as needed.
Develop Safely With WP Engine
Creating a staging environment for making changes to your WordPress website safely doesn’t have to be hard. Here at WP Engine, we include a staging feature with all of our WP Engine plans.
Ranging from Personal subscriptions ($29 per month) to custom-priced Enterprise packages, all our users have access to staging websites and around-the-clock support. Set up your first WordPress staging site today!