From claude-backup
Manage Claude Code backups — sync config and sessions, list/restore sessions, check status. Use when the user asks about backups, restoring sessions, or migrating their Claude environment.
How this skill is triggered — by the user, by Claude, or both
Slash command
/claude-backup:backupThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
You operate the `claude-backup` CLI on behalf of the user.
You operate the claude-backup CLI on behalf of the user.
Always pass --json to get structured output. Never parse human-readable output.
The CLI ships with this plugin. Resolve it in order:
bash ~/.claude/plugins/marketplaces/claude-backup/cli.sh (plugin install)claude-backup (global npm install)On first invocation, try option 1. If the file doesn't exist, fall back to option 2. Store the working path and reuse it for the rest of the session.
All examples below use $CLI as placeholder. Replace with the resolved path.
| Intent | Command |
|---|---|
| Initialize backup | $CLI init --json |
| Initialize (local only) | $CLI init --local --json |
| Initialize with backend | $CLI init --backend <github|git|local> --json |
| Run a backup | $CLI sync --json |
| Backup config only | $CLI sync --config-only --json |
| Backup sessions only | $CLI sync --sessions-only --json |
| Check backup status | $CLI status --json |
| List all sessions | $CLI restore --list --json |
| List recent N sessions | $CLI restore --last N --json |
| Find sessions by project | $CLI restore --project NAME --json |
| Find sessions by date | $CLI restore --date YYYY-MM-DD --json |
| Preview a session | $CLI peek UUID --json |
| Restore a session | $CLI restore UUID --json |
| Restore (overwrite) | $CLI restore UUID --force --json |
| Export config tarball | $CLI export-config --json |
| Import config tarball | $CLI import-config FILE --json |
| Switch backend mode | $CLI backend set <github|git|local> --json |
| Switch to custom remote | $CLI backend set git --remote URL --json |
| Set backup schedule | $CLI schedule <off|daily|6h|hourly> --json |
| Restore all sessions | $CLI restore --all --json |
| Restore all (overwrite) | $CLI restore --all --force --json |
| Restore from machine | $CLI restore --all --machine SLUG --json |
| Uninstall scheduler | $CLI uninstall |
{"ok": true, …} with exit code 0{"error": "message"} on stderr with exit code 1status response includes "mode": "github", "mode": "git", or "mode": "local", plus "machine", "machineSlug", and "schedule" fields--backend <mode> during init to set backend (github, git, local). --local is kept as alias for --backend localUse peek --json before restoring to confirm the right session. Summarize
the preview naturally: "This session from Feb 27 was about debugging auth
middleware — 47 messages. Want me to restore it?"
export-configrestore --list, then peek to confirmstatus) -> gentle nudgenpx claudepluginhub tombelieber/claude-backup --plugin claude-backupManages Claude Code user config (~/.claude/) with actions for audit/status, backup/restore, cleanup sessions/agents/debug/logs, costs/storage/session-stats, history/transcript-search, plugin-reset, and more.
Discovers, searches, and selectively restores Claude desktop app sessions hidden across multiple accountIds on Mac/Windows. Use for recovering lost sessions after account switches.
Exports Claude Code session data to JSON for backup or analysis using claude-view tools. Activates on 'export sessions', 'download data' requests.