You should always upgrade to the latest version of PHP as it provides better performance and compatibility with the latest versions of WordPress.
The following describes how to prepare your site for an upcoming WordPress release.
Since version 5.6, which was released in late 2020, new installs of WordPress have been set to automatically upgrade the core software to the latest available release — whether it's major or minor — shortly after it has been made available for download.
This means that a large number of WordPress sites have been receiving major releases to their core WordPress software without any issues over a period of time. So, you can be assured that WordPress will continue to work as expected when pending updates are made to your site.
Nevertheless, given the large number of themes, plugins, and other customizations that you may have added to your WordPress install, there are a number of variables that should be taken into account to make sure your upgrade process goes smoothly.
Backing up your site and database
Before you make any updates to your WordPress site, Dreamhost recommends backing up your WordPress installation. The following describes how to back up your site for either a One-Click Install or DreamPress.
While DreamHost does not offer on-demand backups in the DreamHost panel for WordPress sites installed through the one-click installer, there are two options for making sure you have a backup before an upgrade occurs:
- Install a WordPress backup plugin (easiest)
- Run a manual backup (advanced — requires using the command line and logging into your site via SSH)
The most important thing here is to make sure that whatever backup you perform is saved onto your local computer or uploaded to a cloud service such as Google Drive or Dropbox. That way, you'll have an off-site backup to restore from in case something unfortunate occurs to your site during the upgrade process.
DreamPress users have the ability to create an on-demand backup of a DreamPress site. See the following article to learn more about how to create a DreamPress backup:
Updating your plugins
One of the things that make automatic WordPress upgrades go smoothly is making sure any out-of-date plugins have been updated before the new WordPress version is released.
Leading up to major releases of WordPress, plugin developers are contacted and asked to make sure that their code is compatible with the changes being made to the core software. You may notice a week or two before a new release that a number of your site's plugins and themes have updates available. This is generally because the developers are preparing their plugins for a new release.
Fortunately, updating plugins is as simple as logging into your site and making a few selections:
If the plugin is part of the core functionality of your site (e.g., WooCommerce, Easy Digital Downloads, Paid Memberships Pro, and so on) DreamHost suggests that you create a backup before updating (see above). However, if the plugin is a little more basic (e.g., Akismet, Smash Balloon, Site Kit, and so on) you may wish to consider enabling automatic plugin updates, so you have one less thing to worry about.
How to test a pre-release WordPress version
The following steps are only necessary if there is an upcoming WordPress version available that is not yet officially released and you would like to test.
If your site leverages some sort of advanced functionality, such as eCommerce or memberships, it's best to "test" your site against the new WordPress version before upgrading. You can create a staging site to accomplish this.
A staging site is basically a secondary environment where you make a copy of your current site. You can then use a tester plugin to test changes (such as updated plugins, new designs, and upgraded core software) on your staging site before updating your live site.Using staging is totally optional, but it's an important best practice to ensure that everything looks, works, and feels right before the upgrade occurs.
Setting up a staging site
You can set up a staging environment depending on the type of hosting plan you are currently on.
See the following article to quickly set up a staging environment on DreamPress:
All other DreamHost hosting plans
See the following article to learn more about staging for Shared, VPS, and Dedicated hosting plans, which is a bit more of a manual process:
You can also use a plugin such as Migrate Guru to move your site files and database to a secondary install, which simplifies the process considerably.
Using the WordPress Beta Tester plugin to test your site
After you create a staging site, use the following instructions to test it.
- Log into your staging site.
- Install the WordPress Beta Tester plugin. Once activated, go to Tools » Beta Testing in the WordPress Dashboard and then select Bleeding Edge:
- Click Save Changes and then select the Release Candidates Only option when the page reloads:
- Click Save Changes again and then go to the Dashboard » Updates page.
- When a Release Candidate (RC) of the next version of WordPress is available, you'll have the ability to update your staging site to it:
Release Candidates are effectively "preview" copies of WordPress that are ready to release so long as there are no major or site-breaking bugs.
- Once your staging site is on the most recent Release Candidate, ensure that everything is fully functional. Here are a few things to check:
- Are all the pages still displaying as they should?
- Is anything unexpected happening when you browse around or try to create new content?
- If you run an eCommerce site, are you still able to add products to the cart and check out?
If something isn't appearing or working as you expect, note what's breaking and reach out to the developer of whichever plugin or theme that is having issues. They may already have a pending update that fixes what you're seeing. Or, if they don't, you may have found something that can be fixed quickly and will save a lot of other users from having a poor upgrade experience.
You can also contact DreamHost support if you have any questions about your WordPress experience.