Many people hand Claude Code (Claude's developer tool that reads and edits code from your terminal) a long file and get the feeling it only looked at the top. This guide explains why that can happen and what you can do about it, limited to what the official docs support. It takes about 10 to 15 minutes to follow.
🟢 Model references match the current lineup · model notice · Fable subscription
Fable 5 and 5.1 subscription (updated November 1, 2026): Claude Fable 5.1, released September 1, 2026, is the current Fable model and Fable 5 is now legacy. Plan terms are the same for both — Max, Ultra, and Team Premium plans include Fable at up to 50% of the weekly usage limit; Pro and Team Standard use usage credits ($10/M input, $50/M output tokens). The one-time $100 credit applied only to the Fable 5 transition and is not offered for 5.1. Some coding and debugging requests may be answered by an Opus model due to a security classifier (both models). See the Fable 5.1 guide and the Fable 5 availability guide for details.
What you will be able to do
You will understand how Claude Code reads files, and you will be able to write prompt wording and CLAUDE.md rules (a instructions file Claude Code reads at the start of every session) that ask for full reads.
Before you start
- Claude Code installed and signed in — this guide assumes you already use it.
- A project folder — you have run
claudeinside it. - Version — the whole-file read option below is documented for v2.1.296 or later. Check your own version on screen.
Quick glossary
- Read tool — the built-in feature Claude Code uses to read file contents.
- Context window — the working notepad Claude can keep in view at one time.
- Token — the unit Claude uses to count text, roughly a word fragment.
- offset / limit — values that say which line to start from (offset) and how many lines to read (limit).
- Hook — a command that runs automatically at a set moment, regardless of what Claude decides.
Why does Claude Code seem to read only part of a file?
Because long files are read in pages rather than all at once. According to the docs, one Read call returns at most 25,000 tokens by default and refuses a whole file over 256 KB, so Claude reads larger files in pages using offset and limit. If a file exceeds the limit, the first part comes back with a PARTIAL view notice that explains how to read more.
So continuing is possible, but whether Claude continues is its own call. With a vague request it may proceed from the first page. The docs do not say how often this happens.
How can you get Claude to read the whole file?
State the range you want in your request, and put recurring requirements in CLAUDE.md. Follow these steps.
Step 1. Name the range in your prompt
Type something like this in the Claude Code input box, replacing the path with your own file.
Read src/app/page.tsx all the way to the end before you start.
If it does not fit in one read, keep reading, and confirm you have read all of it before editing.
You know it worked when Claude reads the same file in several passes, or says it has read the whole file before it begins work.
The docs say that on v2.1.296 or later, Claude can set allow_large: true to read a whole file or a long line range in one call when needed, for example when you asked for the entire file. That read is sized against the room left in the context window.
Step 2. Put recurring rules in CLAUDE.md
If you are tired of repeating yourself, add a few lines to the CLAUDE.md in your project folder. The docs say specific, concise instructions are followed more consistently. For example:
## File reading rules
- Read the entire file before editing it. Never edit based on a partial view.
- If a file is too long for one read, continue with offset and limit until the end.
- If you could not read all of it, say how far you got before editing.
Watch out: a concrete behavior like the lines above works better than a vague one such as "read carefully." The docs also suggest keeping each CLAUDE.md under 200 lines, because longer files reduce adherence.
The three options in the diagram differ in how firmly they apply.
- Prompt — applies to this request only and is the simplest option.
- CLAUDE.md — loaded every session, but the docs say it is delivered as a user message rather than part of the system prompt, and strict compliance is not guaranteed.
- Hooks — the docs advise turning anything that must run at a specific point into a hook instead of a CLAUDE.md line. See the official hooks guide for setup.
Step 3. Check that your instructions actually loaded
Type /context in the session and look for your CLAUDE.md under Memory files. If it is missing, Claude cannot see it. Edit the file itself in your editor (as of November 1, 2026 the official docs describe /memory as the auto-memory toggle).
You know it worked when the CLAUDE.md you just wrote appears under Memory files. If not, check that you started claude inside the project folder. A CLAUDE.md in a subfolder loads on demand rather than at launch, so it is normal for it not to appear in that list.
Step 4. If the file is simply too long, change the approach
- If you are looking for something specific — ask Claude to find the relevant part with Grep (a content search feature) instead of reading everything. The docs also point to Grep when a read exceeds the limits.
- If it is a large file you use often — splitting it by feature makes both reading and editing easier.
- If you want to change the limit — the docs say the per-read limit can be changed with the
CLAUDE_CODE_FILE_READ_MAX_OUTPUT_TOKENSenvironment variable. A larger value uses more context, so choose carefully.
Common sticking points
- Could it edit after reading only part? — per the official docs, the Edit tool only applies after the file was read in the current conversation, and a read cut short with a PARTIAL view notice does not count. So an edit cannot land while Claude has only the first page (the docs also note that newer models can edit a file they have not read when reading it would need no permission prompt, so keep using the step 1 wording to be safe).
- Not sure whether instructions conflict — run
/doctor prompt-auditin a session; it looks for instructions written for older models, references to missing files or commands, and files that contradict each other, and proposes edits (nothing changes until you ask). - It ignores my CLAUDE.md — the official docs say compliance is weakest with vague or conflicting instructions. Check for contradictory guidance across CLAUDE.md files and make the wording more specific.
- Reading whole files fills the context quickly — a long file takes up that much of the notepad. Reading only the needed range is often better.
- You see a
PARTIAL viewnotice — this is not an error. It means only the first part was received. Ask Claude to continue to the end.
Frequently asked questions
Q. Does Claude Code always read only part of a file?
No, paged reading applies to large files that exceed the limits. According to the docs, a single read returns up to 25,000 tokens by default, and files over 256 KB are not read whole.
Q. Will adding a rule to CLAUDE.md guarantee full reads?
No guarantee. The docs treat CLAUDE.md as context rather than enforced configuration and recommend hooks for behavior that must always happen.
Q. How do I check that my instructions loaded?
Run /context and look at the Memory files list. A file that is not listed there is invisible to Claude.
Related: CLAUDE.md complete guide, Claude Code hooks, Why token usage spikes and how to cut it.
Figures and behavior in this article follow the official docs as of November 1, 2026. For details, see the official pages How Claude remembers your project and Tools reference. Behavior can change between versions, so check what appears on your screen before important work.