A staging site is a copy of your site where you can break things safely.
Note: A copy of a database-driven site (WordPress, a shop, a forum) needs a second database. One database is included with your account; an extra one is a £0.99 one-off add-on. Add-ons: extra email accounts, domains, databases, disk space and bandwidth
1. Create the subdomain
Create staging.yourdomain.co.uk. How to create a subdomain
2. Copy the site
WordPress: Softaculous can clone an installation to the subdomain, copying files and database and adjusting the URL. Look for the clone option in your installations list in Extra Features then Softaculous Auto Installer.
Other sites:
- Copy the files into the subdomain’s folder.
- Export the database and import it into a new database. How to export a database (backup with phpMyAdmin) How to import a database with phpMyAdmin
- Point the copy’s configuration at the new database.
- Update any hard-coded URLs to the staging address.
3. Keep it private
- Password-protect the folder. How to password-protect a folder
- In WordPress, tick Discourage search engines in Settings → Reading.
4. Test
- Plugin and theme updates
- A new PHP version, set just for the subdomain How to change the PHP version in DirectAdmin
- Design changes
Putting changes live
Staging databases drift from live ones as new orders, comments and posts arrive, so don’t copy the staging database over live on an active site. Repeat the tested changes on live instead, or copy only files.
Disk space
A staging copy doubles the space the site uses. Delete it when you’re not using it.