{"name":"--debug-file","slug":"debug-file","family":"cli","title":"CLI flags","noun":"CLI flag","description":"Write debug logs to a specific file path. Implicitly enables debug mode. Takes precedence over `CLAUDE_CODE_DEBUG_LOGS_DIR`","description_source":"docs","described_by":{"doc":"claude-code\/cli-reference","title":"CLI reference"},"presence":{"first_seen":"2.1.138","removed_in":null,"in_current_build":true,"newest_mined":"2.1.308","builds":149,"mined_builds":149,"first_cited":{"version":"2.1.20","released_at":"2026-01-27 00:39:43","spans":5}},"aliases":[],"entries":[{"version":"2.1.281","anchor":"tmux-worktree-relaunch-absolutizes-path-arguments","heading":"--tmux worktree relaunch absolutizes path arguments","line":"When --tmux relaunches Claude Code for a worktree, relative file paths in flags are now turned into full paths","released_at":"2026-09-23 17:01:17","reason":"found in this entry's text"},{"version":"2.1.280","anchor":"debug-log-hint-message-reworded","heading":"Debug-log hint message reworded","line":"The dim hint pointing to debug logging now spells out what the debug file explains","released_at":"2026-09-22 15:44:39","reason":"found in this entry's text, named in this entry"},{"version":"2.1.248","anchor":"messaging-warning-hint-offers-the-full-log","heading":"Messaging warning hint offers the full log","line":"The messaging warning now offers the full log instead of telling you to rerun with --debug-file.","released_at":"2026-08-27 20:35:36","reason":"found in this entry's text"},{"version":"2.1.233","anchor":"plugin-eval-verbose-now-writes-traces-to-the-debug-log","heading":"plugin eval --verbose now writes traces to the debug log","line":"Eval --verbose now writes traces to the debug log instead of streaming them live.","released_at":"2026-08-14 18:50:44","reason":"named in this entry, found in this entry's text"},{"version":"2.1.227","anchor":"debug-logging-rebuilt-around-a-single-logger-instance","heading":"Debug logging rebuilt around a single logger instance","line":"Debug logging now runs through one logger that keeps queued lines when it restarts.","released_at":"2026-08-10 20:56:57","reason":"named in this entry, found in this entry's text"},{"version":"2.1.20","anchor":"debug-logging-to-file","heading":"Debug Logging to File","line":null,"released_at":"2026-01-27 00:39:43","reason":"found in this entry's text"}],"entries_total":6,"docs":[{"source":"claude-code","path":"cli-reference","title":"CLI reference","documented":true},{"source":"claude-code","path":"changelog","title":"Claude Code changelog","documented":false},{"source":"claude-code","path":"claude-apps-gateway-deploy","title":"Claude apps gateway deployment and operations","documented":false},{"source":"claude-code","path":"costs","title":"Manage costs effectively","documented":false},{"source":"claude-code","path":"env-vars","title":"Environment variables","documented":false},{"source":"claude-code","path":"hooks","title":"Hooks reference","documented":false},{"source":"claude-code","path":"hooks-guide","title":"Automate actions with hooks","documented":false},{"source":"claude-code","path":"mcp","title":"Connect Claude Code to tools via MCP","documented":false},{"source":"claude-code","path":"monitoring-usage","title":"Monitoring","documented":false},{"source":"claude-code","path":"network-config","title":"Enterprise network configuration","documented":false}],"docs_total":13,"gates":[],"related":[{"name":"--debug","slug":"debug","description":"Enable debug mode with optional category filtering, such as `--debug='mcp,startup'` or `--debug='!1p'`. The filter binds only in the `=` form; a space-separated filter enables debug mode without filtering"},{"name":"--debug-to-stderr","slug":"debug-to-stderr","description":"Debug logging now runs through one logger that keeps queued lines when it restarts."}],"url":"https:\/\/changelogs.core-directive.com\/reference\/cli\/debug-file","family_url":"https:\/\/changelogs.core-directive.com\/reference\/cli.json"}