Claude Code caps concurrent prompt and agent hooks
Version 2.1.312 of Claude Code puts a ceiling on how many prompt and agent hooks run at once. The release note reads:
Changed prompt and agent hooks to run at most 24 at a time per session, sub-agents included, plus at most 12 that have waited longer than their event's timeout; a
timeoutunder 1 second now counts as 1 second
What changes
Two limits now apply to each session:
- At most 24 prompt or agent hooks run at a time. Subagents are counted in that total.
- At most 12 more can run that have already waited longer than their event's timeout.
A hook timeout below one second now counts as one second.
Who should look
Most setups never get near 24. If you fan out many subagents that each trigger a prompt or agent hook, you are the case this limit is aimed at.
The release note names only prompt and agent hooks. It does not mention command or HTTP hooks.
Source: Claude Code changelog, 2.1.312.