clodcapture

Chrome extension that auto-captures every claude.ai chat session to local IndexedDB as you work. Zero-dependency vanilla JS, local-first, on the Chrome Web Store.

clodcapture

Auto-save, export, and continue AI chat sessions across conversations.

Chrome Web Store | Privacy Policy


The problem

Claude.ai has no native session export. Conversations vanish when context fills up. If you're deep in a debugging session or multi-day project and hit the limit, you lose continuity. Copy-pasting manually is tedious and lossy.

What clodcapture does

A Chrome Extension (Manifest V3) that runs silently in the background, capturing every claude.ai conversation as you work. Zero setup, zero login, all data stays local.

Core pipeline

  1. Auto-capture on navigation - Content script patches history.pushState / replaceState and listens for popstate. Every time you open or switch a chat, it fires a capture via the service worker.
  2. Cookie-based auth fetch - Reads your existing claude.ai session cookies to call the conversation API. No API key needed for capture.
  3. IndexedDB storage ("brainjar") - Full raw JSON stored locally. Index metadata (name, message count, timestamps) kept in chrome.storage.local for fast listing.
  4. Background sync - 30-minute alarm cycle captures all conversations automatically.

Export modes

ModeWhat it does
CopyDistills to clean {title, messages[]} JSON, copies to clipboard
GrabDownloads raw API response as timestamped JSON
Sync AllBatch-exports every captured chat to Downloads/clodcapture/
GitHub PushPushes to a configured owner/repo with commit messages. Auto-push on capture optional.

clawd-continue

The session resumption feature. When you want to continue a captured conversation in a new chat:

  1. Distills the raw capture into a clean session format (roles + text only)
  2. If an Anthropic API key is configured: sends to Claude Sonnet with a specialized system prompt that produces an intelligence report (entity extraction, arc mapping, current state, next step) - not a message-by-message recap
  3. If no API key: generates a fallback prompt with the session JSON embedded
  4. Injects the result directly into the active claude.ai composer via ClipboardEvent dispatch

Context usage gauge

  • With API key: exact token count via /v1/messages/count_tokens against a 200k window
  • Without API key: character-based estimation (chars / 3.5)
  • Rendered as a dashed ring gauge in the popup

Architecture

manifest.json          MV3, service_worker, content_scripts on claude.ai
  |
  +-- background.js    364 lines. IndexedDB ops, auth fetch, capture/sync/export
  |                     pipeline, GitHub push, context counting, alarm scheduler
  |
  +-- content.js       61 lines. History API patching, auto-capture triggers,
  |                     composer injection for clawd-continue
  |
  +-- popup.js         429 lines. Full UI render, button handlers, settings panel,
  |                     progress animations, chat list management
  |
  +-- popup.html       268 lines. Glassmorphism shell, DM Sans typography,
  |                     custom CSS animations, responsive layout
  |
  +-- spider.js        36 lines. Interactive canvas spider web animation.
  |                     Click to make the spider bounce on its web.
  |
  +-- intercept.js     1 line. Token data relay from MAIN world

Total: ~1160 lines. Zero dependencies. No build step. No framework.


Permissions and why

PermissionReason
storage + unlimitedStorageIndexedDB + chrome.storage for captures
tabsDetect active claude.ai tab, read URL for chat ID
cookiesCookie-based auth to fetch conversations without requiring API key
downloadsExport JSON files to Downloads/
clipboardWrite/ReadCopy distilled sessions, paste into composer
scriptingInject content script for clawd-continue composer loading
alarms30-minute background sync cycle

Host permissions scoped to claude.ai and api.anthropic.com (token counting) and api.github.com (backup).


Design

  • Color: #D97757 terracotta throughout - progress bars, badges, gauge, spider, status dots
  • UI: Dark glassmorphism shell with backdrop-blur, subtle gradients, spring animations (cubic-bezier(.34,1.56,.64,1))
  • Progress: Custom dashed SVG progress bars that grow segment-by-segment
  • Spider: Interactive canvas animation in the popup header - the spider sits on a web and bounces when clicked
  • Typography: DM Sans 400/500/700

Status

Published on the Chrome Web Store. Currently pending review.