Why Claude Code feels slow — and why "slow" is really five different problems
Why is Claude Code so slow? Usually because of one of five layers: Anthropic's service, your network, growing context, sequential tool round trips, or a heavy model at high effort. Diagnose the layer before changing anything.
Two-minute triage: is it the service or your local session?
This six-step split resolves most slowdowns in two minutes:
- Reproduce it with a fresh, trivial prompt in a new session.
- Check the Anthropic status page for an active incident.
- Check your own network for silent stalls.
- Run
/usageand/contextand read the behavior flags. - Apply the layer-specific fix the checks point to.
- Prove it by re-running the same task and comparing wall time.
If a fresh one-liner is also slow, suspect the service or network; if only long sessions crawl, suspect local context and round trips.
Figure 1: Two-minute triage decision tree
Capture one turn's wall time and /usage totals before clearing diagnostic state. Then check Anthropic's status page, which logged degraded-performance incidents across Aug 12–20, 2026 (90-day uptime ~99.4%); wait if one is active.
What "slow" actually means
"It's slow" is not diagnosable; the shape is. Match your symptom to its layer:
- Slow startup → install/extensions/environment (
/doctor). - Slow first token → context re-processing, cache miss, or service stall.
- Slow generation → model, effort, and fast-mode territory.
- Pauses between tool calls → sequential round trips; the model turn is the cost.
- ~30 s freezes mid-task → silent local network drops with retry and backoff.
- Slow after long sessions → auto-compaction reading the whole conversation.
Service and network causes
Most people blame Anthropic when the cause is local. In one practitioner's 35-day dataset of 74,493 turns, 325 of 375 API errors (~87%) were local connection drops (ECONNRESET, ENOTFOUND); only 12 were 429 rate limits and 6 were 529 overloaded. Claude Code retries these silently with backoff, so they surface as unexplained ~30-second pauses, not errors.
Check: run with --verbose and watch where the pause sits — between request and response is network; during file reads is local work. Proof: switch your network path (wired, VPN off) and re-run; if the stalls vanish, that was the cause.
Context causes: why Claude Code gets slower over time
The model keeps no state between turns, so Claude Code re-sends the whole transcript every request, processing more tokens before the first reply as it grows. But the data calms the panic. Median turn time rises sublinearly, then plateaus: ~1.1 s under 25K tokens, ~5.2 s past 700K (roughly 5x from empty to full), then flat. p90 holds near 19–22 s throughout, so worst-case spikes are a separate problem, not context growth.

Prompt caching absorbs most of that cost: the repeated prefix (system prompt, CLAUDE.md, prior turns) is re-read at the cached rate until it's invalidated. That window is one hour on a subscription, five minutes on credits or API. A longer gap, or switching model, editing CLAUDE.md, or changing MCP servers mid-session, forces a full reprocess. /usage flags long context or cache misses; /context shows what fills the window.
/compact reads the whole conversation it summarizes, so compacting a large context is itself slow. One practitioner measured ~123 s median, cutting context ~84% before it regrew ~22% within 10 turns. Use a focus (/compact keep only the plan and the diff); when you don't need continuity, /clear is free. The Autocompact is thrashing... error means a large output refilled the window: read files in chunks or /clear.
Model and effort causes
Two levers get conflated: how hard the model reasons, and which model runs. After context, effort is the bigger per-turn lever. /effort (low | medium | high | xhigh | max, default high) governs how many tool calls the model makes before answering; lower effort means fewer calls and turns. It works on Fable 5, Opus 5, Sonnet 5, Opus 4.8, and Opus 4.7, via /effort, --effort, or CLAUDE_CODE_EFFORT_LEVEL. Test it by dropping high to medium on a routine task.
The default model resolves to Opus 5 on Max and Enterprise pay-as-you-go, Sonnet 5 on Pro and Team Standard. Lighter models like Haiku 4.5 answer routine turns faster. /fast (research preview, Opus 5 and Opus 4.8 only) buys up to 2.5x output speed at $10/$50 per MTok from credits. It's a latency purchase, not a quality change. If the model is your bottleneck, choose a faster Claude model; for plan meters, understand Claude usage limits.
Tooling causes: round trips, MCP, CLAUDE.md
The structural cost is sequential round trips. A single "fix this bug" on a ~100K-token session commonly expands into 6–10 steps, each paying a full 2–4 s model turn while local tool time is negligible (Read ~0.01 s, Bash ~0.12 s). Because 74.9% of tool-calling turns issued exactly one tool call, most work is strictly sequential. Naming several files up front lets Claude batch reads into one turn. External tools are the exceptions: WebFetch ~5 s, WebSearch ~9.3 s, Subagent ~2.4 s median.
Config bloat inflates every turn. Keep CLAUDE.md small (under ~200 lines), disable unused MCP servers with /mcp (their tool definitions consume the window), and delegate verbose work to subagents. Agent teams (experimental, CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1) use about 7x the tokens, since each teammate runs its own context window.
A controlled test: native Claude Code vs the same harness on Fast
Once the model is your bottleneck, prove it: hold the harness and task constant and swap only the model. fast claude on points all six Claude Code model slots at one catalog model (default glm-5.2) and backs up your settings. It routes your existing harness to a separately billed catalog model; it does not raise native subscription quotas or speed up an unchanged proprietary model.
The method: run a fixed task natively and capture wall time and /usage; then fast claude on --model <catalog-id>, re-run the identical task, and compare. Verify each route (native in /usage, Fast in the Usage dashboard), then revert with fast claude off, which restores your snapshot byte-for-byte.
#!/usr/bin/env bash
set -euo pipefail
# --- Native run: measure your current setup first ---
# Run a fixed task natively, then capture per-session token/cost totals with /usage
# (type /usage inside the Claude Code session). Record wall time and turns.
# e.g. "Refactor src/auth to use the new session helper and update its tests."
# --- Fast run: route the same harness to a selected catalog model ---
fast claude on --model "<catalog-id>" # points all six model slots at the catalog model; backs up settings.json
fast claude status # confirm the adapter reports "on"
# Restart Claude Code, then re-run the identical task. Fast requests appear in the
# Usage dashboard (https://fast.inference.net/dashboard/usage) with the selected model.
# --- Restore: revert to your original configuration ---
fast claude off # restores the original settings.json snapshot byte-for-byte| Route | Model | Task wall time | Turns | Verified in |
|---|---|---|---|---|
| Native | your default | ___ | ___ | /usage |
| Fast | <catalog-id> | ___ | ___ | Usage dashboard |
Fill the blank cells with measurements from the same task on each route (C-001, C-004).
For setup, run fast claude on, choose a model, and verify the route.
Fix matrix and escalation checklist
Act from this matrix. Each row gives a symptom, its likely layer, a check, a fix, and the proof:
| Symptom | Likely layer | Check | Fix | Proof |
|---|---|---|---|---|
| Service degraded | Anthropic service | status page | wait or route to Fast | fresh prompt fast |
| Silent ~30s stall | Local network | --verbose | wired, VPN off | stalls gone |
| Slow first token | Cache miss | /usage flags | keep 1h cache | flag clears |
| Session gets slower | Context size | /context | /compact focus | turn time drops |
/compact thrashing | Compaction | thrash error | chunk reads or /clear | context stays low |
| Slow generation | Effort level | /usage | /effort medium | fewer turns |
| Slow generation | Heavy model | /model | lighter model or /fast | faster tokens |
| Every turn slow | Config bloat | /context | trim CLAUDE.md, /mcp | base context drops |
| Token spikes | Agent teams | /usage | disable teams | ~7x fewer tokens |
| Broken or slow start | Install/env | claude doctor | claude --safe-mode | starts clean |
Sources: C-006, C-007, C-009–C-014, C-018, C-019, C-021, C-022, C-026, C-027.
#!/usr/bin/env bash
# ============================================================
# DIAGNOSE — find where the time goes before changing anything
# ============================================================
# In the Claude Code session (slash commands):
/usage # per-session token/cost stats; flags long context and cache misses [C-006]
/context # what is filling the context window right now [C-007]
/doctor # in-session check of install, settings, extensions, context [C-012]
# In your shell:
claude doctor # same automated check when the CLI won't start [C-012]
claude --verbose # print each tool call as it runs, exposing where the pause sits [C-026]
claude --safe-mode # start with plugins, MCP servers, and hooks disabled to isolate a cause [C-021]
# ============================================================
# ADJUST — the levers that change latency per turn
# ============================================================
# In the Claude Code session (slash commands):
/effort medium # fewer tool calls before answering (low|medium|high|xhigh|max; default high) [C-018]
/model # switch to a lighter/faster model for routine turns [C-020]
/compact keep the plan # summarize history with a focus; the summary read is itself a large request [C-014]
/clear # free reset when you do not need conversation continuity [C-014]For stubborn cases:
- CLI won't start or acts broken →
claude doctor, thenclaude --safe-modeto isolate a plugin, MCP server, or hook. - High CPU or memory on large repos →
/compactregularly, restart between tasks, and add build dirs to.gitignore; use/heapdumponly if memory stays high (never share it — it holds the full conversation and credentials). - Hang or freeze →
Ctrl+C; if unresponsive, close the terminal andclaude --resume(the conversation is preserved). - WSL slow or incomplete search → move the project to the Linux filesystem, or install system ripgrep and set
USE_BUILTIN_RIPGREP=0.
If you have outgrown Claude Code entirely, it may be time to consider Claude Code alternatives.
Next step: test the model route
If the model was your bottleneck, test the same harness on a Fast model without leaving the CLI.
Run Claude Code on Fast Inference
Keep the Claude Code harness, route model traffic to a selected Fast model, and restore your original settings with fast claude off.
See the Claude Code guideRelated Reading
- Run Claude Code on Fast Inference — install the reversible Fast route.
- Codex Usage and Limits — understand plan limits.
- Inference Economics — compare inference costs.
References
- Anthropic — Claude Code costs: https://code.claude.com/docs/en/costs
- Anthropic — troubleshooting: https://code.claude.com/docs/en/troubleshooting
- Anthropic — model config: https://code.claude.com/docs/en/model-config
- Anthropic — status: https://status.claude.com/
- AakashX — Why Claude Code Gets Slower: https://www.aakashx.com/blog/why-claude-code-is-slow/