Claude AI's 200K context window feels like a city with no walls. You can drop in a 50-page contract, a dense research paper, a full PDF chapter from a textbook. The Document API accepts it. The chat returns an answer. The workflow feels solved.
Then you open the API dashboard, or re-read the answer, or try to add a second document to a Project that already feels heavy. And you start to wonder what is actually going on inside that file.
That city has a dragon. The dragon lives quietly inside every PDF you upload, eating tokens, dulling answers, and growing every time you feed it. Most Claude users never see it. The ones who do split into three groups, and only one group walks out with a better workflow.
The 200K Context Window Trap: Why Claude Users Think PDFs Are Fine
When Anthropic released the Document API, the message was simple: Claude reads PDFs natively. Drop the file in, ask your question, get an answer. The model accepts files up to 32MB and 100 pages per document. Projects on claude.ai let you persist the same PDF across conversations, so a reference doc only needs to be uploaded once.
This is the city. It feels safe because the architecture supports it. The PDF goes in, the response comes out, and there is no error message telling you anything went wrong.
The trap shows up in small ways. A summary that misses a key clause buried on page 23. A specific question that gets a vague answer. A Project that hits its file limit faster than it should. Each one looks like a one-off issue. None of them feel connected to the file format. They are.
The Hidden Token Cost of Uploading PDFs to Claude
The dragon's first claw is the token bill.
Claude processes PDFs through two layers running together. The first is a vision pass: the model looks at each page as an image, parsing visual hierarchy, tables, embedded charts, and any non-text elements. The second is text extraction: an OCR step pulls out the literal characters, including footnotes, headers, footers, and any artifacts the original PDF carried with it.
Both layers feed into the context window. According to Anthropic's own pricing documentation, a single PDF page consumes between 1,500 and 3,000 tokens on average. A 25-page research paper, then, runs around 47,000 tokens before you have asked a single question.
Convert the same paper to Markdown first, and the token count drops to roughly 5,200. Same content. Same headings. Same data tables. One ninth of the cost. Multiply that across a Project with 10 documents and you have spent 470,000 tokens on storage that could have been served by 52,000.
On Claude Sonnet 4.5 rates, that math puts the bill at roughly $1.40 per Project just to hold documents in context, before any actual conversation begins. For teams running dozens of Projects across legal, research, and engineering, the number compounds quickly. The dragon stays quiet. The meter keeps running.
How Claude AI Actually Reads PDF Files
To understand why the cost runs so high, look at what Claude does the moment a PDF lands in its context.
The Document API processes each page in those two layers. A page with sparse text can still cost 1,500 tokens because the vision pass is doing structural work that the text alone cannot describe. For a page with tables, charts, or figures, the cost climbs to 2,500 or 3,000 tokens, since the model needs to encode visual relationships in token form.
Markdown skips both layers entirely. There is no image to analyze, no OCR to run, no layout to infer. The tokens you pay for are the tokens that carry meaning. Anthropic's own guidance recommends Markdown for any document you plan to reuse across conversations, which confirms the math from inside the company that built the model.
Three Ways to Handle PDFs in Claude (Only One Works)
Once a Claude user sees the dragon, they pick one of three responses. The first two are the ones the dragon prefers.
Response 1: Ignore the dragon
The most common path. The user keeps dropping PDFs into chats and Projects, accepts the answers Claude gives, and never checks the token economics. Costs accumulate quietly. Answer quality drifts downward on long documents. The user assumes Claude is just average at this kind of work, when the file format is doing most of the damage.
This path costs the most over time. It also produces the worst answers, because the user never associates the friction with the input format.
Response 2: Pay for a bigger plan
The proud path. The user notices something is off, opens the pricing page, and upgrades. More context, faster model, higher rate limits. The reasoning sounds clean: bigger plan, bigger documents, problem solved.
The dragon scales with the plan. A larger context window holds more PDFs, which means more vision passes, more OCR work, more tokens consumed per question. The bill grows in proportion to the upgrade. Answer quality on individual documents stays where it was, because the file format still buries the structure the model needs to read.
This is the Pride and Fall path. The user spent more money to make the dragon bigger.
Response 3: Convert to Markdown first
The path that actually works. The user runs the PDF through a converter, gets clean Markdown out, and feeds that into Claude. Token cost drops by 80 to 90 percent. The model reads explicit headings, properly aligned tables, and clean lists. Answers tighten. Projects hold more documents without strain. The rest of this article walks through how to do it.
Why Markdown Beats PDF for Claude (Token and Accuracy Comparison)
The token savings are the surface gain. The deeper gain is accuracy.
Claude was trained on enormous quantities of Markdown. GitHub READMEs, technical documentation, Stack Overflow posts, internal docs. The format is part of the model's native vocabulary. When Claude sees ## Methodology, it registers a section boundary, a hierarchical signal, a structural cue about what follows.
A PDF page does not carry those signals in a form Claude can use directly. The OCR layer might recover the word “Methodology” in 14-point bold, and the model then has to infer that the formatting means “section heading.” That inference burns tokens, and sometimes the inference fails. On a research paper with five major sections, those failures compound into a flatter understanding of the document.
Here is a direct comparison from a 25-page academic paper run through both flows:
| Metric | PDF upload | Markdown upload |
|---|---|---|
| Tokens consumed | ~47,000 | ~5,200 |
| Cost per query (Sonnet 4.5) | ~$0.14 | ~$0.016 |
| Section heading recall | 3 of 5 | 5 of 5 |
| Table data accuracy | 78% | 96% |
| Cross-page citation accuracy | 64% | 91% |
The numbers come from a single test, so treat them as directional. The direction is consistent across every run we have observed, and it lines up with the broader pattern we documented in our analysis of ChatGPT and PDFs.
How to Convert a PDF to Markdown for Claude in 30 Seconds
The conversion is the shortest part of the workflow.
- Open pdftomd.cloud in a new tab. The free tier covers 3 conversions per month, which is enough to test the flow on real documents before committing.
- Drag the PDF onto the converter. The processing runs on Claude Haiku 4.5 under the hood, so the output is structurally aware: tables become Markdown tables, headings nest properly, lists keep their hierarchy.
- Copy the Markdown output or download the
.mdfile. - Paste the Markdown into your Claude conversation, or upload the
.mdfile directly to a Claude Project.
The first time you run this with a document you have already chatted with as a PDF, ask Claude the same question you asked before. Compare the two answers side by side. That comparison is what makes the change stick.
Claude Projects + Markdown: The Workflow That Scales
Projects are where Markdown pays the largest dividend.
A Project on claude.ai is a persistent workspace with its own attached documents and instructions. Claude references those documents in every conversation inside the Project. The token cost of loading those documents is paid on every message you send, so whatever inefficiency exists in the document set gets charged again every time you hit Enter.
A Project loaded with PDFs carries that overhead into every conversation, sometimes consuming so much of the context window on document loading that the actual conversation gets cramped. A Project loaded with Markdown does the same job at roughly one tenth the cost per turn, leaving room for longer threads, more attached files, and richer custom instructions.
For research, this means you can hold 30 papers in a Project without saturating context. For legal review, a full contract library fits in the same space that previously held five PDFs. For technical documentation, an entire API reference plus changelog plus runbook can live in one Project at the cost of what one PDF reference used to consume.
This is the workflow the dragon was hiding.
5 Mistakes That Make Claude Burn Your Token Budget
The path stays clean as long as you avoid a handful of common slips.
- Uploading scanned PDFs without OCR. A scanned page hits the vision pass twice as hard, with no clean text layer to fall back on. Run an OCR pass first, then convert to Markdown.
- Skipping headings during conversion. A wall of unstructured Markdown loses most of the format advantage. Use a converter that preserves hierarchy. PDFtoMD does this by default because Claude Haiku is structurally aware.
- Mixing languages without demarcation. Claude handles multilingual documents well, but unflagged language shifts confuse the model and waste tokens on retry attempts. Use explicit section markers for language switches.
- Letting Projects collect old files. Every attached file gets loaded on every message. Clean Projects monthly, archive what is no longer relevant, keep only what is in active use.
- Re-uploading the same PDF across multiple chats. Convert once, save the Markdown locally, reuse the file. The dragon feeds on every re-conversion.
FAQ: Claude AI and PDFs
Can Claude AI read PDFs directly?
Yes. Claude reads PDFs through the Document API, which combines vision-based page analysis with text extraction. Files can be up to 32MB and 100 pages per document.
What is Claude's PDF size limit?
32MB per file and 100 pages per document. The context window itself holds up to 200,000 tokens, which a single large PDF can fill quickly because of the vision pass cost.
How many tokens does a PDF use in Claude?
Roughly 1,500 to 3,000 tokens per page, depending on visual complexity. A 25-page paper averages around 47,000 tokens in PDF form. The same content in Markdown lands closer to 5,200 tokens.
Is Markdown better than PDF for Claude?
Markdown produces lower token costs and higher answer accuracy. In a direct test on a 25-page paper, Markdown improved section recall from 3 of 5 to 5 of 5, raised table data accuracy from 78% to 96%, and cut cost per query by roughly 90%.
Can Claude read scanned PDFs?
Yes, through the vision pass, with significantly higher token cost and lower accuracy than text-based PDFs. Run scanned files through an OCR pass before converting to Markdown for the cleanest output.
How do I upload a PDF to Claude Projects?
Open the Project, click the attachment icon, select the file. The PDF persists across all conversations in that Project. For better economics, convert the PDF to Markdown first and upload the .md file instead.
Does Claude support images inside PDFs?
Yes, through the vision layer of the Document API. The trade-off is token cost: image-heavy PDFs consume tokens faster than text-only documents, and the visual analysis adds latency to each query.
The Takeaway
The dragon lives inside the file format. Claude itself reads Markdown the way it was trained to read it: as structure, hierarchy, and meaning. The conversion takes less time than the question you are about to ask. The savings start on the first prompt and compound on every prompt after.
Run one document through both flows this week. Ask Claude the same question of each. The answer will decide the rest of your workflow.
