AI News Daily한국어
← AI tool tips
Claude Code✓ Confirmed in official docsAdded Nov 15

How to turn on Claude Code Code Mode to batch tool calls into one piece of code

Claude Code v2.1.323 (November 12) added Code Mode, an experimental feature. With it on, Claude stops calling Bash, Read and Edit one at a time and instead writes one piece of JavaScript that makes several tool calls in a single step. Use it for a change that repeats across many files, a search whose results need filtering before Claude reads them, or independent commands that can run at the same time.

  1. Check your version and update if it is older than v2.1.323.
claude --version
claude update
  1. Start with the environment variable set to 1. To try it once, set it in your shell.
CLAUDE_CODE_EXPERIMENTAL_CODE_MODE=1 claude

To turn it on for every new session, put it in ~/.claude/settings.json. Claude Code ignores this variable in a project's settings files, so a repository you clone can't turn it on for you.

{
  "env": {
    "CLAUDE_CODE_EXPERIMENTAL_CODE_MODE": "1"
  }
}
  1. At the first launch, pick Yes, turn on Code Mode. After the restart, the line Code Mode (experimental) is on near the top means it worked.

  2. The conversation shows only the tool calls. To read the code Claude wrote, press Ctrl+O to open the transcript viewer and expand a Code row.

The requirements are strict. It runs only in an interactive claude session in a terminal (native build), not with -p, VS Code, the Desktop app or cloud sessions. The model must be Opus 5.5, Sonnet 5.5, Haiku 5.5 or Fable 5.2, and the account a Claude subscription or Console account; Bedrock, Vertex and gateways are out. It won't start with an API key helper, agent teams, OpenTelemetry export or DISABLE_TELEMETRY on. If it doesn't start, the reason appears in the top line and in /status.

A few things to know. A Code Mode session resumes with claude --continue or --resume only while the variable is still 1. Code you wait on stops after ten minutes. Auto mode's classifier reviews the whole piece of code but not values computed at run time (such as a path taken from search output), so guard calls you must control with deny rules or a PreToolUse hook (matcher REPL). To turn it off, remove the variable or set it to 0. To block it for an organization, set it to 0 in the env of managed settings.

Get notified when a new tip lands

Tip alerts only go out in the app. Install it and turn notifications on.

Get the app

All tips →