Available in
Marketplaces, most starred first
Tags
Add to README
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
By pdhooliav0.3.0MITIn 1 marketplace
Trace Claude Code conversations, tool calls, subagent executions, and context compaction to Langfuse
You run one by typing its /name in Claude Code.
1 critical · 3 cautions to review before installing
A hook runs before every tool call and can block or approve it
A hook runs when Claude uses the Bash tool
A hook runs when Claude writes or edits files
A command runs shell commands (! syntax) when you invoke it
Static checks of hooks, mods, MCP servers and commands. Not a security audit.
1 marketplace, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
A Claude Code plugin that traces conversations to Langfuse with full fidelity — multiple LLM generations per turn, thinking blocks, token usage, and properly nested tool observations.
Session (session_id)
└── Trace: "Claude Code - Turn N"
├── Generation: "LLM Call 1/3" (model, usage, thinking in output)
│ ├── Span: "Tool: Glob" (input, output, duration_ms)
│ └── Span: "Tool: Read" (input, output, duration_ms)
├── Generation: "LLM Call 2/3" (model, usage)
│ └── Span: "Tool: Edit" (input, output, duration_ms)
└── Generation: "LLM Call 3/3" (model, usage, final response)
output.thinking fieldinput_tokens, output_tokens, cache metrics in metadatamessage.id are concatenated/plugin marketplace add pdhoolia/langfuse-claude-code-plugin
/plugin install langfuse-tracing@langfuse-claude-code-plugin
/reload-plugins
Clone the repo and build:
git clone https://github.com/pdhoolia/langfuse-claude-code-plugin.git
cd langfuse-claude-code-plugin
pnpm install
pnpm build
Then run Claude Code with the plugin directory:
claude --plugin-dir /path/to/langfuse-claude-code-plugin
The plugin reads these env vars (full reference table below). Most users
set credentials and Langfuse host once globally in ~/.claude/settings.json,
then control which projects get traced via the two-knob model
below. Shell exports also work if you prefer the per-shell-session pattern.
Tracing is off by default. The plugin exits silently unless either:
TRACE_TO_LANGFUSE=true is set (typically in a project's .claude/settings.json), orCC_LANGFUSE_TRACE_DEFAULT=all is set globally.See Enabling tracing selectively below for the recommended setup.
| Variable | Default | Description |
|---|---|---|
TRACE_TO_LANGFUSE | (none) | Per-invocation override. true → trace; false → don't trace. Wins over the global default. See Enabling tracing selectively. |
CC_LANGFUSE_TRACE_DEFAULT | (none — opt-in) | Global default policy. all → trace by default unless a project opts out. Anything else / unset → opt-in (don't trace unless a project opts in). |
CC_LANGFUSE_PUBLIC_KEY | falls back to LANGFUSE_PUBLIC_KEY | Langfuse public key |
CC_LANGFUSE_SECRET_KEY | falls back to LANGFUSE_SECRET_KEY | Langfuse secret key |
CC_LANGFUSE_BASE_URL | https://cloud.langfuse.com | Langfuse API host (for self-hosted) |
CC_LANGFUSE_DEBUG | false | Enable debug logging |
CC_LANGFUSE_MAX_CHARS | 50000 | Max characters before truncation |
The expectation is that you install the plugin once globally and then
declare per-project whether each project should be traced. Two env
vars make that work; you only ever set them inside Claude Code's
settings.json files.
Built from public signals: copy clicks on this site, GitHub stars and activity, the README and the manifest. Not a security audit or an endorsement.
npx claudepluginhub pdhoolia/langfuse-claude-code-plugin --plugin langfuse-tracingPlugins from other owners that cover similar ground