Downloading and Restoring Backups
Once you've created a backup, Stack2X makes it easy to download the files to your computer or restore them directly to a Supabase instance. This guide covers both options.
Downloading a Backup
From the Backups page in your sidebar, find the backup you want to download. Click on it to open the backup detail view.
Downloading Individual Files
Each backup component is listed separately -- database, auth, storage, edge functions, and project config. Click the Download button next to any component to grab just that file. This is useful when you only need a specific piece, like your database schema or auth users.
Downloading as ZIP
If you want everything in one go, click Download All (ZIP) at the top of the backup detail view. Stack2X packages all components into a single ZIP file and starts the download. Depending on the size of your backup, this may take a few moments.
Restoring a Backup
Restoring a backup pushes the backed-up data back into a Supabase instance. This is useful for disaster recovery, setting up a staging environment, or rolling back after an unwanted change.
Selecting the Target Instance
From the backup detail view, click Restore. You'll be asked to choose a target instance -- the Supabase project where you want the data restored. This can be the same instance the backup came from or a different one. Both need to be connected to your Stack2X organization.
Picking Components to Restore
Just like when creating a backup, you can choose which components to restore. You might want to restore only your database without overwriting auth users, or restore storage files without touching anything else. Select the components you need and leave the rest unchecked.
Understanding the Impact
Stack2X shows a summary of what will be affected before you confirm. Restoring a component replaces the existing data in the target instance with the backed-up version. This is a destructive action for the selected components, so review the summary carefully.
Monitoring the Restore
After clicking Confirm Restore, Stack2X begins the process. A progress indicator shows which component is being restored and an estimated time remaining. Like backups, restores run in the background, so you can navigate away and come back later.
Verifying the Restore
Once the restore completes, Stack2X marks it as successful and logs the event in your activity feed. It's a good idea to spot-check the restored instance by logging into your Supabase project and verifying that your tables, users, and files look correct.
If any component fails during the restore, Stack2X reports the error and leaves the remaining components untouched. You can review the error, fix the issue, and retry just the failed component.