# PDF rejected: check the three hard limits
## Symptom
The request fails when a PDF is attached: 400 on the document block or 413 on the request.
## Confirm the cause
Check three things: total request size against 32 MB (the whole payload counts, not just the PDF), page count against 600 pages (100 when the request's context window is under 1M tokens), and whether the PDF has a password or encryption, which is not supported. Encrypted or nonstandard PDFs are the silent killer when size and pages look fine.
## Fix
1. Split oversized PDFs into chunks under the limits.
2. Upload with the Files API and reference the returned `file_id` in document blocks to keep payloads small, especially for repeated analysis of the same file.
3. Remove passwords or encryption before sending; convert nonstandard PDFs to standard ones.
4. Enable prompt caching on repeated analysis of the same document.
## Verify
The same analysis on a small unencrypted PDF succeeds first; then scale back up chunk by chunk. The Files API reference path is the check for the size-bound cases.