Memory spike: 3 processes peaked at 12.7 GB combined on 18 GB machine (v2.1.34, macOS native)

Resolved 💬 5 comments Opened Feb 8, 2026 by Piesson Closed Feb 25, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report
  • [x] I am using the latest version of Claude Code

What's Wrong?

Three Claude Code processes spiked to a combined peak of 12.7 GB on an 18 GB machine (71% of total RAM). System swap hit 96%.

This is not a team/multi-agent session. Just normal single-user work — reading files, editing code, running tools.

The Numbers

Captured with footprint -p claude --swapped on Feb 8, 2026:

Peak memory per process:

| PID | Current | Peak | Top Consumer |
|-----|---------|------|-------------|
| 97354 | 4,414 MB | 5,810 MB | WebKit malloc: 3,057 MB |
| 94672 | 1,597 MB | 3,715 MB | WebKit malloc: 850 MB |
| 63744 | 2,276 MB | 3,215 MB | WebKit malloc: 1,738 MB |
| 3 others | 1,015 MB | ~1,200 MB | — |
| Total | 9,301 MB | ~12,740 MB | WebKit malloc: 6,381 MB |

Two additional problems:

  • Zombie processes found: PID 64816 alive for 16 days, PID 28807 alive for 26 days. These sessions ended long ago but the processes never exited.
  • Swap nearly full: 24,581 / 25,600 MB used (96%). Swapins: 765M.

Root Cause Hint

WebKit malloc is responsible for 6.3 GB out of 9.3 GB total dirty memory. IOAccelerator (GPU) adds another 2.3 GB. These two categories alone account for 93% of all memory used.

This suggests the WebView layer is not releasing DOM/rendering memory between conversation turns or after context compaction.

Environment

  • Claude Code: 2.1.34 (native macOS app)
  • macOS: 26.1 (Tahoe, Build 25B78)
  • Chip: Apple M3 Pro
  • RAM: 18 GB
  • Model: Opus 4.6 (1M context)

Steps to Reproduce

  1. Use Claude Code native for a few hours across multiple sessions
  2. Run footprint -p claude --swapped
  3. Observe memory growth and zombie processes

Workaround

pkill -9 claude reclaims all memory.

Related Issues

  • #23883 — 13-16 GB in Team mode (Windows, v2.1.34)
  • #22162 — API client leak (macOS, high-priority)
  • #4953 — 120+ GB OOM kill (Linux, oncall)

View original on GitHub ↗

This issue has 5 comments on GitHub. Read the full discussion on GitHub ↗