=== Stagecopy - Backup, Migration & Staging ===
Contributors: storynova
Tags: backup, migration, staging, clone, restore
Requires at least: 5.8
Tested up to: 6.8
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

One-button backup, migration and staging for WordPress. Built to finish on cheap shared hosting. No yearly fees.

== Description ==

Stagecopy does three things and does them with one button each.

**Backup.** Database and every file into one zip. Download it, restore it, keep it. Backups are chunked so a 3 GB site finishes on a host with a 30-second limit.

**Migrate.** Make a backup on the old site, upload it on the new one. Stagecopy rewrites every URL, file path and table prefix, including serialized and JSON data, then restores. Your login survives the move.

**Staging.** One click clones your site to /staging with its own database tables and a noindex header. Test updates there. One click pushes it back to live, with an automatic backup of live first.

**What's free**

* Unlimited manual backups and restores of your site
* Database-only quick backups
* Export packages
* Create a staging site to test updates on
* Keeps your 2 newest backups

**What's in Pro** (one payment, every site you own, forever)

* Migration: import a package onto any site with full URL, path and prefix rewriting
* Staging: one-click push from staging back to live, with an automatic backup first
* Scheduled daily or weekly backups
* Keep up to 100 backups
* Priority email support

**Built for bad hosting**

Every long task is split into short steps that save their progress. If a step is cut off by a timeout, the next request picks it up. Large files are stored uncompressed to save CPU. The backup folder is protected from direct web access.

**Nothing leaves your server**

Backups stay in a protected folder inside wp-content. Stagecopy does not phone home, collect analytics or store your data anywhere.

== Installation ==

1. Upload the `stagecopy` folder to `/wp-content/plugins/`, or install from Plugins > Add New.
2. Activate the plugin.
3. Open Stagecopy in the admin menu and press "Back up now".

== Frequently Asked Questions ==

= Where are backups stored? =

In `wp-content/stagecopy-backups-<random>/`, protected by .htaccess and web.config. Download them from the Backups tab to keep an off-site copy.

= Does migration work between different domains and hosts? =

Yes. That is the main job. It also handles a different table prefix and a different folder path.

= Will I be logged out during a restore? =

No. Stagecopy preserves the account you're signed in with across the import. If you are, just sign in again; the restore continues from where it was.

= Does staging work on every host? =

Staging is created as a subfolder (yoursite.com/staging) using the same database with a different table prefix, which works on almost every host without DNS or cPanel changes. Hosts that block subfolder installs are rare.

= Is there a file size limit for uploads? =

No. The migration package uploads in 2 MB pieces, so PHP upload limits do not apply.

== Screenshots ==

1. Backups tab with one-button backup and your backup list.
2. Migration import by drag and drop.
3. Staging site created with one click.

== Changelog ==

= 1.0.0 =
* First release: chunked backups, restore, migration with URL/path/prefix rewriting, staging create/push/delete, scheduled backups (Pro).
