> Documentation index: https://docs.kiste.run/llms.txt, a list of every page in this documentation.

# Checkpoints and snapshots

> Automatic encrypted off-site checkpoints every five minutes, named snapshots, retention and restoring a snapshot as a new Kiste.

Kiste keeps your work in two kinds of restore points:

- **Automatic checkpoints**, taken for you, always on.
- **Named snapshots**, taken when you ask, kept until you delete them.

Both are snapshots of the Kiste's disk, both are copied off-site encrypted, and
both can be restored as a new Kiste.

## Automatic checkpoints

Every Kiste is checkpointed:

- **every five minutes when its disk changed** (nothing is taken while it is
  idle);
- **when it stops**, **before it restarts**, **before it is forked** and
  **before it is deleted**.

A checkpoint is taken with the Kiste's file system frozen for a moment, so it
is consistent like a cleanly unmounted disk. When the Kiste is writing too
heavily to freeze in time, the checkpoint is taken anyway and marked
`crash`-consistent: like a power cut, every write that was flushed is in it.

Change the interval when you create a Kiste, from 60 seconds to one day:

```bash
kiste new data-job --auto-snapshot 15m
```

Checkpoints can't be switched off.

### Off-site and encrypted

Each checkpoint is copied to object storage in the EU, in **two independent
locations**. Only the parts of the disk that changed since the last checkpoint
are uploaded. Everything is compressed and encrypted with AES-256-GCM under a
key that belongs to your account alone, before it leaves the computer that runs the Kiste; the
storage holds no readable data, not even file names. A checkpoint counts as
off-site only once both locations hold all of it.

`kiste status` shows when the newest checkpoint was taken and when it was held
off-site:

```text
checkpoints  Saved 3 min ago · off-site 4 min ago · every 5 min when the disk changed
```

### How long checkpoints are kept

For each Kiste:

| Age | Kept |
| --- | --- |
| Any | The newest three, always |
| Last hour | Every checkpoint |
| Last 24 hours | The newest of each hour |
| Last 14 days | The newest of each day |

Older checkpoints are deleted automatically. When you delete a Kiste, its last
checkpoint is taken and its automatic checkpoints are kept for **14 days**, so
a Kiste deleted by mistake can still be restored. After that they are deleted.
Named snapshots are never deleted automatically.

## Named snapshots

```bash
kiste snapshot create review-42 --name before-upgrade
kiste snapshot create --name before-upgrade        # the current Kiste
```

Takes a snapshot of a running Kiste's disk now. Without `--name`, the name is
the Kiste's name and the time, such as `review-42-20261006-142530` (UTC). Named
snapshots are copied off-site like checkpoints, and they stay, also after the
Kiste is deleted, until you delete them:

```bash
kiste snapshot delete SNAPSHOT_ID_OR_NAME
```

Snapshots count toward your account's disk limit.

## List snapshots

```bash
kiste snapshot list
```

The list shows every snapshot and checkpoint of your account with its source
Kiste, its trigger (`manual`, `interval`, `stop`, `restart`, `fork` or
`delete`), its state, age and size, and its off-site state (`uploaded ×2` when
both locations hold it, `uploading`, `pending` or `failed`). The console shows
them under **Snapshots**.

## Restore

```bash
kiste snapshot restore SNAPSHOT_ID_OR_NAME review-42-restored
```

Restoring creates a **new, independent Kiste** from the snapshot; the Kiste the
snapshot came from is not touched, and neither is the snapshot. The new Kiste
boots fresh from the restored disk and has the size of the original.

Recent checkpoints still have a copy next to the Kiste and restore instantly.
Older ones restore from the off-site copy: the new Kiste starts right away and
fetches its disk in the background as it reads it, so you don't wait for the
whole disk to download.

In the console, choose **Restore** on a snapshot and enter a name.

## What a snapshot does not contain

A snapshot holds the disk, not the memory: a restored Kiste boots fresh. A
saved session (`kiste stop --snapshot`) is a different thing, see
[Lifecycle](https://docs.kiste.run/kisten/lifecycle.md#stop-and-keep-the-session).

## Errors you may see

| Code | Meaning |
| --- | --- |
| [K08](https://docs.kiste.run/errors/k.md#k08) | There is no snapshot with that ID in your account. |
| [L04](https://docs.kiste.run/errors/l.md#l04) | Your Kisten and snapshots use all the disk your account may use. Delete snapshots or Kisten you don't need. |

## Related topics

- [Overview](https://docs.kiste.run/kisten.md)
- [Create a Kiste](https://docs.kiste.run/kisten/create.md)
- [Lifecycle](https://docs.kiste.run/kisten/lifecycle.md)
- [Fork](https://docs.kiste.run/kisten/fork.md)
- [Manage](https://docs.kiste.run/kisten/manage.md)
- [Images and environments](https://docs.kiste.run/kisten/images.md)
- [Automation](https://docs.kiste.run/kisten/automation.md)
- Previous: [Lifecycle](https://docs.kiste.run/kisten/lifecycle.md)
- Next: [Fork](https://docs.kiste.run/kisten/fork.md)
