Claude Code

Stop @ File Mentions From Pasting Whole Files Into Your Claude Chat

Tagging a file with @ puts its whole content in the chat, up to 25,000 tokens. The one setting that hands Claude just the path instead, how to turn it on, and the catch

2min read
1prompts to copy
4numbered steps
5sections

When you tag a file with @ in Claude Code, the file's content goes into the conversation, as long as it fits the Read tool's limit of 25,000 tokens by default. Tag a few big files and a lot of your chat is files you may not have needed.

Here's the setting that changes it, how to turn it on, and what you give up.

Step 1: update Claude Code

  1. The setting arrived in Claude Code 2.1.299 (October 14, 2026). Update Claude Code, then run claude --version to check.

Keep reading

Free, for an email.

Unlocks 4 more sections, 1 copy-paste prompt, the document version, and every other guide on the site, for free. Enter your email once to keep reading.

45,000+ follow where these guides come from.No spam. Unsubscribe in one click.

Read next