mysi Find

Brief in AI engineering

Image and file input limits for model APIs

States per vendor which images and files a model API accepts, size and page limits, and image token cost.

Anthropic counts 28 px patches, OpenAI 32 px patches (older models: 512 px tiles), Gemini fixed budgets set by media_resolution. Images per request: 600 (Anthropic), 1,500 (OpenAI), 3,600 (Gemini). PDF pages: 600 (Anthropic), 1,000 (Gemini).

Facts

Limit Anthropic OpenAI Google Gemini
Images per request 600 [1] 1,500 [4] 3,600 [7]
Image size limit 10 MB base64 on the Claude API [1] 512 MB total request payload [4] not stated
Largest image 8000x8000 px [1] 30,000 patches after resizing [4] not stated
Image tokens ⌈width / 28⌉ × ⌈height / 28⌉ [1] ⌈width / 32⌉ × ⌈height / 32⌉ patches × model multiplier [4] 258 per 768x768 tile [7]
PDF size 128 MB per request [2] under 50 MB per file [5] 50 MB per file [9]
Files API storage 1 TB per organization [3] 2.5 TB per project [6] 20 GB per project [10]
Files API lifetime until deleted [3] until deleted [6] 48 hours [10]
  • Anthropic: 100 images per request on models with a 200k-token context window [1].
  • Anthropic: 5 MB base64 per image on Amazon Bedrock [1].
  • Anthropic: above 20 images in one request, a stricter pixel limit applies to every image; 3,000 px per side stays under it [1].
  • Anthropic: Claude 4.7 and later downscale images to at most 2,576 px long edge and 4,784 tokens [1].
  • Anthropic: other models downscale images to at most 1,568 px long edge and 1,568 tokens [1].
  • Anthropic: an oversized image in a tool_result is rejected, not downscaled [1].
  • Anthropic: 100 PDF pages per request when the context window is under 1M tokens [2].
  • Anthropic Files API: expires_in_seconds from 3,600 (1 hour) to 7,776,000 (90 days) [3].
  • Anthropic Files API: out of beta; the files-api-2025-04-14 header is optional [3].
  • OpenAI: an image over 30,000 patches is rejected, not resized [4].
  • OpenAI image token multiplier: 1.2 on current models such as GPT-6 Astra and GPT-5.5 [4].
  • OpenAI detail values: low, high, original, auto; the default is auto [4].
  • OpenAI detail: "high" on current models: up to 2,500 patches [4].
  • OpenAI file inputs: 50 MB combined across all files in one request [5].
  • OpenAI Chat Completions accepts only PDF files [5].
  • OpenAI Responses API also accepts spreadsheets, Word files, slides, text and code files [5].
  • OpenAI: .docx, .pptx and .txt files give text only; PDFs give text and page images [5].
  • OpenAI spreadsheets: only the first 1,000 rows per sheet are parsed, plus a generated summary [5].
  • OpenAI Files API: purpose=batch files expire after 30 days by default; expires_after sets a policy [6].
  • Gemini: an image with both sides at most 384 px costs 258 tokens [7].
  • Gemini 4 and 3 media_resolution image tokens: low 280, medium 560, high 1120, ultra_high 2240 [8].
  • Gemini 4 and 3: the default image budget is 1120 tokens; the default PDF page budget is 560 tokens [8].
  • Gemini: ultra_high can be set only per content item [8].
  • Gemini 4 and 3 audio: 25 tokens per second at low, medium, high and the default [8].
  • Gemini: 2,000 pages or slides per Office file [9].
  • Gemini: the 50 MB, 1,000-page and 2,000-page limits apply both inline and through the Files API [9].
  • Gemini spreadsheets: up to 50,000 cells per sheet [9].
  • Gemini: requests larger than 100 MB in total must use the Files API [10].

Use it for

  • Choosing inline bytes or an uploaded file id for a given file size.
  • Estimating image and page token counts before a request.
  • Splitting large PDFs or image sets to stay under per-request counts.
  • Not for prices; not for Bedrock, Vertex or Azure limits.

Sources

Tested

Tested 4 Dec 2026: claude-haiku-5-5 stated 5 of its 35 facts without this page and 33 with it; claude-fable-5-2 stated 9 of its 35 facts without this page and 35 with it.

Changes

Cite as: mysi, Image and file input limits for model APIs, mysi.dev/llm-image-and-file-limits, version 1, changed 2026-12-04. Text and data CC BY 4.0.