Getting Started with ClawDNA
ClawDNA is an open-source CLI that treats your AI agent's personality, skills, config, and memory as a portable, versionable artifact. Snapshot your agent's identity, sync it across machines, and deploy fleet-wide updates — all without risking the personality you spent weeks building.
The CLI and self-hosted Git sync are fully open source and free forever. View on GitHub
Architecture
ClawDNA consists of three discrete components that can be used independently or together:
┌─────────────────────────────────────────────────────────────┐
│ clawdna CLI (OSS) │
│ snapshot · restore · push · pull · diff · clone · fleet │
└───────────────────────┬─────────────────────────────────────┘
│ speaks to one of:
┌───────────────┼───────────────────┐
│ │ │
v v v
┌──────────┐ ┌─────────────┐ ┌──────────────────┐
│ Local FS │ │ Git Remote │ │ ClawDNA Cloud │
│ (no hub) │ │ (self-host) │ │ (hosted, paid) │
└──────────┘ └─────────────┘ └──────────────────┘- CLI — TypeScript + Node.js, published to npm. Runs on your machine, manages identity files, communicates with the hub.
- Git Hub — Any standard Git remote (GitHub, GitLab, Gitea). Free. The CLI handles all Git operations internally via
isomorphic-git. - ClawDNA Cloud — Cloudflare Workers API + R2 storage. Hosted sync hub with memory distillation, fleet management, and team features.
Prerequisites
- Node.js >= 22
- pnpm (recommended) or npm
Install
$ npm install -g @clawco-io/dnaUpdating
To update ClawDNA to the latest version:
$ npm install -g @clawco-io/dna To safely update your agent's runtime (OpenClaw) while protecting your identity, use the built-in clawdna upgrade command instead — it auto-snapshots before the update and verifies identity integrity after.
$ clawdna upgradeQuick Start
1. Initialize ClawDNA in your agent workspace
$ clawdna init The init wizard detects your agent workspace and walks you through hub configuration (Cloud, Git remote, or local-only).
2. Create your first identity snapshot
$ clawdna snapshot --name "initial-setup" This creates a timestamped .dna bundle — a compressed tarball containing all identity files plus a manifest with metadata.
3. Push your identity to the configured hub
$ clawdna pushYour identity is now safely synced. Other environments can pull it, or you can fleet-push to all registered machines at once.
Local Development
$ git clone https://github.com/triplehelix/clawdna.git
$ cd clawdna
$ pnpm install
$ pnpm buildMonorepo Structure
| Package | Path | Description |
|---|---|---|
clawdna | packages/cli | CLI tool — published to npm |
@clawdna/cloud | packages/cloud | Cloudflare Workers sync API |
Next Steps
- CLI Reference — All 14 commands with flags and examples
- Concepts — Identity files, bundles, sync protocol, environments
- Security — Secrets sanitizer, encryption, permissions
- API Reference — Cloud API endpoints
