BrainwriteDocs
Self-hosting

Data and backups

Know what Brainwrite stores locally and what to preserve.

Brainwrite keeps its application state under ~/.brainwrite, including configuration, transcripts, message attachments, device pairing state, and the SQLite message store.

Back up

Close Brainwrite before taking a filesystem-level backup so SQLite and configuration files are captured consistently. Preserve the entire .brainwrite directory rather than selecting individual database files.

Do not copy secrets casually

Packaged desktop builds may protect credentials using operating-system secure storage. Copying the JSON directory to another machine does not necessarily make protected credentials usable there, and it should not be treated as a portable credential export.

Disposable computer filesystems

Local VM workspaces are mounted durably, but a self-hosted VPS container filesystem is intentionally disposable. Move important artifacts to a durable workspace, repository, or connected app before removing or upgrading a container.

For a headless npm server, engine credentials and configuration live separately in the service user's home, for example .codex, .claude, and .claude.json. Include the paths your installed CLIs use, any configured home/data-directory overrides, browser session state under .agent-browser if used, and external workspaces. Stop any engines or managed desktops still writing those files. A Docker backup of the whole /data volume includes the container's CLI homes.

Restore with the server stopped, preserving the original paths and ownership, then start it again. The VPS backup instructions show the app-data archive and stop/start commands.

On this page