# WebSpace backups

> How FeatherQuilld backs up WebSpaces, the four storage providers (local, S3, restic, PBS), restoring single files, imports and scheduled backups.

Source: https://featherpanel.com/docs/quilld/backups/

FeatherQuilld backs up the files of a WebSpace as a `.tar.gz` archive with a SHA-256 checksum. Where the archive goes
depends on the node's backup provider. Databases are separate; they are not part of the archive.

## Choosing a provider

Set the provider on the web node's **Configuration** tab under **Backup storage**:

| Provider | Where backups go | Settings |
|----------|------------------|----------|
| Local (default) | `<backup directory>/<webspace uuid>/<backup uuid>.tar.gz` with a JSON file next to it | Backup Directory (`system.backup_directory`, default `/var/lib/featherquilld/backups`) |
| S3 | `<prefix><webspace uuid>/<backup uuid>.tar.gz` in the bucket | Endpoint, region (`us-east-1`), bucket, prefix (`webspaces/`), access and secret key, force path style for MinIO and similar |
| Restic | A snapshot per backup, tagged `webspace=<uuid>` and `backup=<uuid>`, host `featherquilld` | Repository, password, optional path to `restic` |
| Proxmox Backup Server | A `host` backup with ID `<webspace uuid>` | Repository (`user@pbs@host:datastore`), password or API token, optional TLS fingerprint and path to `proxmox-backup-client` |

For restic and PBS, install the client on the node yourself. Password fields can be left blank when you edit the node
to keep the saved value. S3, restic and PBS keep a small index of backups in the backup directory so the list loads
quickly.

## Using backups

On the WebSpace's **Backups** page owners and subusers can:

- **Create backup.** The job runs in the background and the page shows its progress. The site keeps running. (The
  API also accepts `stop_during_backup` to stop it while the archive is written.)
- **Download** an archive.
- **Restore** the whole backup, which overwrites the current files, or open it and **Restore selected files**.
- **Import** an existing `.tar.gz` archive (up to 5 GiB).
- **Recheck backup status** to rebuild the list from restic or PBS.
- **Delete** a backup.

Subuser permissions are `backup.read`, `backup.create`, `backup.delete`, `backup.download` and `backup.restore`. Admins
have the same actions on the admin WebSpace page.

## Scheduled backups

A WebSpace schedule task can be `backup`, next to `command`, `restart`, `start` and `stop`. The Nightly Backup preset
on the new schedule page creates a schedule that backs up the WebSpace every day at 03:00 in your timezone. Old backups
are not deleted automatically; remove them by hand or with your storage's own retention (for example `restic forget`
or a PBS prune job).

## Frequently asked questions

### Backups disappeared from the list after I reinstalled the node. Can I get them back?

With restic or PBS, use Recheck backup status on the Backups page. It rebuilds the local index from the repository. With S3 the index lives on the node, so keep the backup directory when you reinstall.

### How big can an imported archive be?

The node accepts uploads of up to 5 GiB for an import.
