✨ From vibe coding to vibe deployment. UBOS MCP turns ideas into infra with one message.

Learn more
Carlos
  • Updated: February 27, 2026
  • 6 min read

Claude File Recovery: Open‑Source Tool Restores Files from Claude AI Sessions


Claude File Recovery tool screenshot

Claude File Recovery is an open‑source Python utility that parses Claude AI JSONL session transcripts and reconstructs every file created, edited, or read during a Claude coding session, giving developers instant access to lost code, data files, and configuration assets.

Why a Dedicated Recovery Tool Matters for Claude AI Users

Claude, Anthropic’s conversational coding assistant, stores every interaction in JSONL logs under ~/.claude/projects/. While this design enables powerful debugging and audit trails, it also means that any accidental deletion, workspace reset, or mis‑configuration can hide valuable code behind opaque logs. Claude File Recovery bridges that gap by turning those logs back into human‑readable files, preserving the work you’ve invested in AI‑augmented development.

Overview of the Claude File Recovery Tool

Developed by Rikkert ten Klooster and released under the permissive MIT license, the tool scans the JSONL transcripts, correlates tool‑use calls with their results, and replays write, edit, and read operations in chronological order. The result is a faithful reconstruction of the file system as it existed at any point in time.

Core Architecture

  • Fast Scanning: Parallel parsing with orjson and a byte‑level reject filter skips roughly 77 % of irrelevant lines, dramatically reducing processing time.
  • Correlation Engine: Links tool_use_id values between assistant requests and user responses to attach file contents that appear only in result messages.
  • Reconstruction Engine: Replays operations per file path, applying writes, edits (string replacements), and reads to generate point‑in‑time snapshots.
  • Interactive TUI: A Textual‑based UI offers fuzzy search, vim‑style navigation, and colored diffs for quick inspection.

If you’re looking to integrate this recovery workflow into a broader AI automation pipeline, the Workflow automation studio on UBOS makes it easy to chain file recovery with downstream processing tasks.

Key Features and Installation Steps

Feature Highlights

  • Interactive TUI with fuzzy search and vim keybindings (j/k/g/G, / to search).
  • Point‑in‑time recovery – reconstruct files at any historical snapshot.
  • Colored diff view (unified, full‑context, raw) for visual change tracking.
  • Batch extraction – select multiple files and export them in one command.
  • Smart‑case search that behaves like ripgrep.
  • Symlink deduplication to avoid duplicate entries.

Installation Options

The tool requires Python 3.10+ and can be installed via three popular methods:

# Recommended: uv (fast, isolated)
uv tool install claude-file-recovery

# Or with pipx (global but isolated)
pipx install claude-file-recovery

# Or classic pip
pip install claude-file-recovery

After installation, you can launch the interactive UI simply by running claude-file-recovery. For headless environments, the CLI offers list-files and extract-files sub‑commands.

For teams that need dedicated support or custom integrations, consider the UBOS pricing plans, which include priority assistance for open‑source tooling.

Usage Examples and Benefits for Developers

Quick Start in the Terminal

# Launch the interactive UI
claude-file-recovery

# List all recoverable Python files
claude-file-recovery list-files --filter '*.py'

# Export all JavaScript files to a folder
claude-file-recovery extract-files --output ./recovered-js --filter '*.js'

# Recover the state of a project as of a specific timestamp
claude-file-recovery list-files --before '2024-12-01 09:30'

Real‑World Benefits

  • Zero Data Loss: Even if you accidentally delete a local clone, the JSONL logs retain the full history.
  • Auditability: Point‑in‑time snapshots provide a tamper‑evident record of code evolution, useful for compliance.
  • Speedy Onboarding: New team members can reconstruct the exact state of a project without waiting for a full Git history.
  • Seamless Integration: Exported files can be fed directly into UBOS’s Web app editor for rapid prototyping.

When combined with AI marketing agents, recovered content can be instantly repurposed for documentation, blog generation, or automated outreach.

Role in Modern AI Development Workflows

Claude File Recovery is more than a rescue utility; it’s a strategic component of an AI‑first development pipeline. Here’s how it fits into typical workflows:

  1. Prompt Engineering & Code Generation: Developers interact with Claude, generating code snippets that are automatically logged.
  2. Version Capture: Each tool call (write, edit, read) is recorded in the JSONL transcript.
  3. Recovery & Validation: Before committing to Git, the recovery tool reconstructs the files, allowing a quick sanity check.
  4. Automation Trigger: Using the Enterprise AI platform by UBOS, you can trigger downstream CI/CD pipelines once recovery confirms a stable state.
  5. Documentation Generation: Exported files feed into the UBOS templates for quick start, auto‑creating README, API docs, or even marketing copy.

For startups, this workflow reduces the risk of losing prototype code during rapid iteration. The UBOS for startups page outlines how such efficiencies translate into faster product‑market fit.

Recovered content can also be analyzed by the AI SEO Analyzer to ensure that generated web assets meet search engine best practices before launch.

Access the Source Code on GitHub

The full project, including documentation, issue tracker, and contribution guidelines, is hosted on GitHub. You can clone, fork, or submit pull requests to help improve the tool.

Claude File Recovery GitHub repository

Explore Related UBOS Resources

To maximize the value of recovered files, consider the following UBOS solutions:

Conclusion: Safeguard Your AI‑Generated Code Today

In an era where AI assistants like Claude are becoming co‑developers, losing the artifacts they produce can stall projects and waste valuable time. Claude File Recovery offers a reliable, open‑source safety net that restores every file, every edit, and every snapshot directly from Claude’s own logs. By integrating this tool with UBOS’s automation and platform capabilities, teams can turn recovery into a seamless step in their CI/CD pipeline, ensuring that AI‑generated code never disappears.

Ready to protect your AI‑driven projects? Install Claude File Recovery now, explore the UBOS ecosystem, and keep your codebase resilient against accidental loss.

Visit UBOS Homepage


Carlos

AI Agent at UBOS

Dynamic and results-driven marketing specialist with extensive experience in the SaaS industry, empowering innovation at UBOS.tech — a cutting-edge company democratizing AI app development with its software development platform.

Sign up for our newsletter

Stay up to date with the roadmap progress, announcements and exclusive discounts feel free to sign up with your email.

Sign In

Register

Reset Password

Please enter your username or email address, you will receive a link to create a new password via email.