npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@makimoto/cc-log-viewer

v0.2.1

Published

Search through Claude Code session logs with full-text search

Readme

@makimoto/cc-log-viewer

A local web app for searching and browsing Claude Code session logs with full-text search.

Indexes all conversation data stored under ~/.claude/projects/ into SQLite FTS5 and serves a searchable web interface.

Quick Start

npx @makimoto/cc-log-viewer

Opens at http://127.0.0.1:8899

Features

  • CLI search mode with JSON output for AI agents and scripting
  • Full-text search across all Claude Code sessions using SQLite FTS5
  • Prefix matching for partial search terms (e.g., "API-8" matches "API-8853")
  • Filter by project, git branch, and role (user/assistant)
  • Session list view with metadata (summary, branch, timestamps)
  • Session detail view with full conversation history
  • Copy claude --resume <session-id> command to resume sessions from terminal
  • Auto-reindex every 3 minutes while the browser tab is open
  • Incremental indexing (only processes new/changed sessions)
  • Keyboard shortcut: / to focus search

Installation

# Run directly (no install needed)
npx @makimoto/cc-log-viewer

# Or install globally
npm install -g @makimoto/cc-log-viewer
cc-log-viewer

CLI Options

Web server (default)

cc-log-viewer [--port <number>] [--host <string>]

CLI search mode

Search and retrieve session data as JSON, suitable for AI agents and scripting.

# Search messages (outputs JSON)
cc-log-viewer search "API-8853"
cc-log-viewer search "API-8" --project td-api --role assistant --limit 10

# List sessions
cc-log-viewer sessions [--project <name>] [--branch <name>] [--limit <n>]

# Get full session detail
cc-log-viewer session <session-id>

Prefix matching is supported: "API-8" matches API-8853, API-8654, etc.

Other options

cc-log-viewer --reindex          Reindex sessions and exit
cc-log-viewer --reindex-force    Force full reindex and exit
cc-log-viewer --stats            Show index stats and exit

How It Works

Claude Code stores session data as JSONL files under ~/.claude/projects/. This tool:

  1. Scans all project directories for session metadata (sessions-index.json) and raw JSONL files
  2. Extracts user and assistant messages, ignoring tool calls and system data
  3. Stores everything in a SQLite database with FTS5 at ~/.claude/cc-log-viewer.db
  4. Serves a web UI for searching and browsing

Configuration

If you use a custom Claude Code config directory via the CLAUDE_CONFIG_DIR environment variable, this tool respects it automatically:

CLAUDE_CONFIG_DIR=/custom/path/to/claude npx @makimoto/cc-log-viewer

By default, ~/.claude/ is used.

Requirements

  • Node.js >= 18
  • Claude Code (session data must exist under the Claude config directory)

License

MIT