« All posts

Identify Slow Hooks in Claude Code — Measure p95 with a One-Line Wrapper

A new wrapper for Claude Code logs execution times of hooks, helping identify performance issues by measuring p95.

In the Claude Code environment, determining which hooks are causing slowdowns can be challenging. This article introduces a wrapper that logs each hook's execution time to a JSONL file. Engineers can pinpoint performance issues by identifying the slow hooks responsible for delays.