A local backup utility for OpenClaw workspaces
Project description
ClawBackup
A local backup utility for OpenClaw workspaces, built for fast first-run setup, scheduled backups, and clean CLI-based recovery workflows.
Languages: English | 简体中文 | 日本語 | 한국어 | Deutsch
Why ClawBackup | What It Backs Up | Core Capabilities | Quick Start | First Run | Development & Release
Why ClawBackup
An OpenClaw workspace usually contains more than just one config file. It often includes credentials, agent profiles, memory files, workspace data, and scheduled tasks. Copying these files manually is easy once, but hard to keep consistent over time.
ClawBackup is designed to make local backup simple and repeatable:
- complete the first backup with a clean CLI flow
- enable scheduled backups without heavy setup
- review, restore, or remove old archives when needed
- install and distribute it using standard Python packaging workflows
ClawBackup fits especially well for:
- individual OpenClaw users who want dependable local backups
- users who frequently edit agent configuration and want rollback safety
- teams that want a standardized backup utility instead of manual file copy steps
What It Backs Up
By default, ClawBackup backs up these OpenClaw files and directories:
openclaw.json: main config filecredentials/: API keys and tokensagents/: agent configs and auth profilesworkspace/: memory files,SOUL.md, and user filescron/: scheduled task configuration
Default paths:
- OpenClaw data directory:
~/.openclaw - Backup output directory:
~/openclaw-backups - Compression format:
zip - Default retention policy: keep latest
10, keep at least3, remove anything older than30days
Core Capabilities
Clean user-first CLI
The default home screen keeps the main workflow focused on four high-frequency actions:
- Back Up Now
- Schedule
- Reset Config
- Exit
Advanced commands such as history, config inspection, and logs are still available from the CLI, but they do not overload the first screen.
Multilingual startup
The app currently supports:
- English
- Simplified Chinese
- Japanese
- Korean
- German
Scheduled backups
Built-in scheduling presets include:
- every 6 hours
- daily at 02:00
- every Sunday at 02:00
- monthly on day 1 at 02:00
- custom cron expressions
Retention control
ClawBackup supports both “keep all backups” and “keep only the latest N backups” retention strategies.
History and restore
For generated archives, ClawBackup supports:
- browsing backup history
- restoring a selected backup
- deleting a single backup archive
Quick Start
Recommended: install with pipx
If pipx is not installed yet:
python3 -m pip install --user pipx
python3 -m pipx ensurepath
Close the current terminal, open a new one, then install the stable release directly from the wheel:
pipx install "https://github.com/Yuan-lab-LLM/ClawBackup/releases/download/v0.1.1/clawbackup-0.1.1-py3-none-any.whl"
After the project is published to PyPI, the same install becomes:
pipx install clawbackup
Run:
clawbackup
Install the latest code from main
pipx install --force "git+https://github.com/Yuan-lab-LLM/ClawBackup.git@main"
Install from local source
If you already cloned the repository:
python3 -m pip install .
or:
pipx install .
Install with pip
If you prefer pip instead of pipx, install the published wheel directly:
python3 -m pip install "https://github.com/Yuan-lab-LLM/ClawBackup/releases/download/v0.1.1/clawbackup-0.1.1-py3-none-any.whl"
After PyPI publishing is enabled, users can also install with:
python3 -m pip install clawbackup
First Run
Recommended first-run flow:
- launch
clawbackup - confirm or adjust the source and backup directories
- run the first backup
- configure scheduling only if you want automatic execution
Shortest path:
clawbackup
If you prefer direct commands:
clawbackup init
clawbackup backup
Common Commands
Main workflow
clawbackup
clawbackup init
clawbackup backup
clawbackup schedule
clawbackup reset
Advanced commands
clawbackup history
clawbackup config
clawbackup log
Upgrade and Uninstall
Upgrade to the latest main branch
pipx install --force "git+https://github.com/Yuan-lab-LLM/ClawBackup.git@main"
Upgrade or install a specific version
pipx install --force "https://github.com/Yuan-lab-LLM/ClawBackup/releases/download/v0.1.1/clawbackup-0.1.1-py3-none-any.whl"
Uninstall
If installed with pipx:
pipx uninstall clawbackup
If installed with pip:
python3 -m pip uninstall clawbackup
Local Files
Runtime files:
- config file:
~/.config/clawbackup/config.json - log file:
~/.config/clawbackup/clawbackup.log
If you want to fully reset local state, use the in-app reset flow or remove the config file manually.
Development and Release
Run locally
python3 clawbackup.py
or:
python3 -m clawbackup
Syntax check
python3 -m py_compile clawbackup.py src/clawbackup/cli.py src/clawbackup/__init__.py
Version locations
Before release, keep these locations aligned:
pyproject.tomlsrc/clawbackup/__init__.py- UI version text inside
src/clawbackup/cli.py
Homebrew files
The repository already contains Homebrew-related files:
Formula/clawbackup.rbscripts/render_homebrew_formula.pyscripts/homebrew_sha256.shscripts/test_homebrew_local.sh
Release checklist
Recommended release flow:
- update version numbers
- commit changes
- create a tag such as
v0.1.1 - push
mainand the tag - verify the GitHub Release
- sync the Homebrew formula if needed
Common commands:
git add .
git commit -m "Release v0.1.1"
git tag v0.1.1
git push origin main --tags
Publish to PyPI
This repository is prepared for PyPI publishing through GitHub Actions trusted publishing.
Before the first publish:
- create the
clawbackupproject on PyPI - in PyPI project settings, add a trusted publisher for:
- owner:
Yuan-lab-LLM - repository:
ClawBackup - workflow:
publish-pypi.yml - environment:
pypi
- owner:
- in GitHub, approve the
pypienvironment if your org requires environment review
After that, the publish flow is:
- build and verify the package locally if needed
- create and push a release tag such as
v0.1.2 - open GitHub Actions and run the
Publish PyPIworkflow, or trigger it from a published release - verify the package on PyPI
Once PyPI publishing is live, end users can install with:
pipx install clawbackup
or:
python3 -m pip install clawbackup
License
This project is released under the MIT License.
Contributing
Issues and pull requests are welcome, especially around OpenClaw backup flows, restore workflows, and scheduling improvements.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file clawbackup-0.1.1.tar.gz.
File metadata
- Download URL: clawbackup-0.1.1.tar.gz
- Upload date:
- Size: 27.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
22db97c71be38e8d0b6de49d83abbf2ec69df79bd1d376298b82b0be7882523e
|
|
| MD5 |
e012216bdc93d25212ff2f6be0b3257a
|
|
| BLAKE2b-256 |
de92a6730d94fc7d5b776529391064315719fa1948a60cb4950bca2734c9eed9
|
Provenance
The following attestation bundles were made for clawbackup-0.1.1.tar.gz:
Publisher:
publish-pypi.yml on Yuan-lab-LLM/ClawBackup
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
clawbackup-0.1.1.tar.gz -
Subject digest:
22db97c71be38e8d0b6de49d83abbf2ec69df79bd1d376298b82b0be7882523e - Sigstore transparency entry: 1348976745
- Sigstore integration time:
-
Permalink:
Yuan-lab-LLM/ClawBackup@b1a1bf832fac531d324e7e88a92323b5e08a96b7 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/Yuan-lab-LLM
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@b1a1bf832fac531d324e7e88a92323b5e08a96b7 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file clawbackup-0.1.1-py3-none-any.whl.
File metadata
- Download URL: clawbackup-0.1.1-py3-none-any.whl
- Upload date:
- Size: 24.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
829337246cb88b51dfb2e719d9e06b99880399dab947743d717d005a0dcb6045
|
|
| MD5 |
809b238a7022298c400fafb3ea4d1feb
|
|
| BLAKE2b-256 |
15496ea11c88c4b49195ed1ca6e59df2984457412033c5ca3234045eb359a5bb
|
Provenance
The following attestation bundles were made for clawbackup-0.1.1-py3-none-any.whl:
Publisher:
publish-pypi.yml on Yuan-lab-LLM/ClawBackup
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
clawbackup-0.1.1-py3-none-any.whl -
Subject digest:
829337246cb88b51dfb2e719d9e06b99880399dab947743d717d005a0dcb6045 - Sigstore transparency entry: 1348976821
- Sigstore integration time:
-
Permalink:
Yuan-lab-LLM/ClawBackup@b1a1bf832fac531d324e7e88a92323b5e08a96b7 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/Yuan-lab-LLM
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@b1a1bf832fac531d324e7e88a92323b5e08a96b7 -
Trigger Event:
workflow_dispatch
-
Statement type: