Ark β Encrypted backup & restore plugin for OpenClaw. Preserve your entire setup and migrate to a new system in one command.
- AES-256-GCM encryption with PBKDF2 key derivation (600K iterations)
- Selective backup/restore β choose which categories to include
- 10 backup categories: config, credentials, wallet, brain, doc-rag, cron, extensions, workspace, devices, identity
- Retention policy β auto-prune old backups by count or age
- Agent tools β
backup_create,backup_restore,backup_list,backup_status - CLI commands β
openclaw backup create|restore|list|prune - Slash commands β
/ark,/ark backup,/ark list,/ark restore,/ark prune,/ark help - Zero external dependencies β uses Node.js built-in crypto, zlib, and a minimal tar implementation
cd ~/.openclaw/extensions
git clone https://github.com/Quackstro/openclaw-ark ark
cd ark && npm install && npm run buildopenclaw plugins install @quackstro/ark- Command Reference β All slash commands, agent tools, and CLI usage
- Architecture β Archive format, encryption, categories, tar implementation
- Migration Guide β Step-by-step guide for moving to a new system
| Command | Description |
|---|---|
/ark |
Status overview |
/ark backup <passphrase> |
Create encrypted backup |
/ark list |
List all backups |
/ark restore |
Restore instructions |
/ark prune |
Remove old backups |
/ark help |
Command reference |
# Create a backup (all categories)
openclaw backup create -p "my-secure-passphrase"
# Create with specific categories only
openclaw backup create -p "my-passphrase" -c config,wallet,brain
# List backups
openclaw backup list
# Restore (all categories)
openclaw backup restore ./backups/openclaw-backup-2026-02-11.ocbak -p "my-passphrase"
# Restore specific categories only
openclaw backup restore ./backup.ocbak -p "my-passphrase" -c config,workspace
# Dry-run restore (preview without writing)
openclaw backup restore ./backup.ocbak -p "my-passphrase" --dry-run
# Prune old backups per retention policy
openclaw backup prune"Create a backup with passphrase 'hunter2'" "Show backup status" "Restore from the latest backup" "List my backups"
{
plugins: {
entries: {
ark: {
enabled: true,
config: {
backupDir: "~/.openclaw/backups",
categories: {
config: true,
credentials: true,
wallet: true,
brain: true,
docrag: true,
cron: true,
extensions: true,
workspace: true,
devices: true,
identity: true
},
retention: {
maxBackups: 5,
maxAgeDays: 30
},
notifications: {
enabled: true,
channel: "telegram",
target: "your-chat-id"
}
}
}
}
}
}| Category | Contains | Sensitive |
|---|---|---|
config |
openclaw.json (API keys, channel tokens) |
π Yes |
credentials |
OAuth tokens, provider credentials | π Yes |
wallet |
DOGE keystore, UTXOs, audit log | π Yes |
brain |
Brain stores (LanceDB), pending actions | No |
docrag |
Ingested documents + embeddings | No |
cron |
Cron job definitions + run history | No |
extensions |
Installed plugins (source code) | No |
workspace |
Agent workspace (AGENTS.md, memory/, scripts/) | Mixed |
devices |
Paired device configs | No |
identity |
Agent identity data | No |
OCBAK1 (6 bytes magic)
Salt (32 bytes β random)
IV (16 bytes β random)
AuthTag(16 bytes β GCM auth tag)
Body (AES-256-GCM encrypted tar.gz)
Key derivation: PBKDF2-SHA512, 600,000 iterations.
- On old system:
openclaw backup create -p "migrate-2026" - Copy the
.ocbakfile to the new system - On new system: Install OpenClaw, then
openclaw backup restore ./file.ocbak -p "migrate-2026" - Restart:
sudo supervisorctl restart openclaw
# Run all tests
npm test
# Or directly
node --test tests/config.test.ts tests/engine.test.ts23 tests covering:
- Config parsing (defaults, overrides, categories, tilde expansion)
- Backup creation, listing, restore (correct/wrong passphrase, dry-run, selective)
- Pruning (max count enforcement)
- Archive format (magic bytes, salt, ciphertext uniqueness)
MIT β Quackstro LLC