> For the complete documentation index, see [llms.txt](https://stoneforgeteam.gitbook.io/stoneforgeteam-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://stoneforgeteam.gitbook.io/stoneforgeteam-docs/getting-started/save-backups.md).

# Save backups

StoneForge keeps backups of your saves, whatever mods you play with (since 0.9.4). Before the game writes a save over an older one, or deletes one (its oldest, to make room, or one you delete in the save menu), StoneForge copies it first. A mod's bug, an error box or a crash in the middle of saving can't take your last good save with it.

|             |                                                                               |
| ----------- | ----------------------------------------------------------------------------- |
| Your saves  | `%LOCALAPPDATA%\StoneShard\characters_v1\<character>\<save>`                  |
| The backups | `%LOCALAPPDATA%\StoneShard\StoneForge\save-backups\<character>\<time>_<save>` |

The newest 20 of each character's backups are kept. They're outside the game's save folder, so neither its save menu nor Steam Cloud sees them. A backup that fails is only logged: it never stops the game saving.

## After a mod's error

The first time any mod's handler throws in a game, StoneForge:

1. keeps the save you're playing (the last one made before the error) as a `before-error_...` backup, which is never deleted with the others;
2. asks whether to leave to the main menu **without saving**. The game may be in a bad state now, and saving would keep it.

It asks once a game.

## Restoring a backup

1. Close the game.
2. Copy the backup's folder into its character's folder in `characters_v1`.
3. Rename it to the save's own name (drop the time from the front: `autosave_1`, say), replacing the save that went wrong.

For mods: `SaveBackups.Keep(label)` keeps a copy of the save being played that's never deleted. See [Rooms and saves](/stoneforgeteam-docs/world/rooms-and-saves.md#save-backups).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://stoneforgeteam.gitbook.io/stoneforgeteam-docs/getting-started/save-backups.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
