{"name":"CLAUDE_CODE_TOOL_MEMORY_LIMIT","slug":"claude-code-tool-memory-limit","family":"env","title":"Environment variables","noun":"environment variable","description":"On Linux you can cap memory for shell commands so a runaway process cannot eat your machine.","description_source":"entry","described_by":{"version":"2.1.233","anchor":"bash-and-powershell-tools-can-run-under-a-memory-limit-on-li"},"presence":{"first_seen":"2.1.233","removed_in":null,"in_current_build":true,"newest_mined":"2.1.309","builds":66,"mined_builds":150,"first_cited":{"version":"2.1.246","released_at":"2026-08-25 19:17:34","spans":2}},"aliases":[],"entries":[{"version":"2.1.295","anchor":"tool-memory-cgroup-skipped-when-ks-is-true","heading":"Memory limit for tool commands is skipped in a certain mode","line":"In a certain mode, Claude Code now skips setting up the memory limit it can place on commands run by tools","released_at":"2026-10-08 18:22:58","reason":"found in this entry's text, named in this entry"},{"version":"2.1.246","anchor":"per-class-memory-caps-on-spawned-processes-wired-through-but","heading":"Per-class memory caps on spawned processes, wired through but off for everything except Bash","line":"Memory limits now reach npm, git, tmux, LSP, MCP and hooks, but everything except Bash is excluded.","released_at":"2026-08-25 19:17:34","reason":"found in this entry's text"},{"version":"2.1.246","anchor":"tool-memory-cgroups-reworked-still-off-unless-turned-on","heading":"Tool memory cgroups reworked, still off unless turned on","line":"Memory caps on processes Claude starts were rebuilt but stay off unless you set the limit variable.","released_at":"2026-08-25 19:17:34","reason":"named in this entry, found in this entry's text"},{"version":"2.1.246","anchor":"tool-subprocesses-can-be-launched-inside-a-memory-capped-cgr","heading":"Tool subprocesses can be launched inside a memory-capped cgroup","line":"MCP servers, hooks, plugin installs and tmux sessions can run under a memory cap, dark-launched here.","released_at":"2026-08-25 19:17:34","reason":"found in this entry's text"},{"version":"2.1.233","anchor":"bash-and-powershell-tools-can-run-under-a-memory-limit-on-li","heading":"Bash and PowerShell tools can run under a memory limit on Linux","line":"On Linux you can cap memory for shell commands so a runaway process cannot eat your machine.","released_at":"2026-08-14 18:50:44","reason":"named in this entry, found in this entry's text"}],"entries_total":5,"docs":[{"source":"claude-code","path":"tools-reference","title":"Tools reference","documented":false},{"source":"claude-code","path":"whats-new\/2026-w33","title":"Week 33 \u00b7 August 10\u201314, 2026","documented":false}],"docs_total":2,"gates":[],"related":[{"name":"CLAUDE_CODE_TOOL_MEMORY_CGROUP_EXCLUDE","slug":"claude-code-tool-memory-cgroup-exclude","description":"Memory limits now reach npm, git, tmux, LSP, MCP and hooks, but everything except Bash is excluded."}],"url":"https:\/\/changelogs.core-directive.com\/reference\/env\/claude-code-tool-memory-limit","family_url":"https:\/\/changelogs.core-directive.com\/reference\/env.json"}