Skip to content

Agents and multimodal systemsAnalysis

What does an image input cost? Tokens per image by provider

An image is billed as input tokens, but each provider reaches the count differently: OpenAI from resized patches, Gemini from a resolution setting, Claude from limits and a count you should measure. This post gives a per-screenshot and per-page calculation and the resize rules that move it.

By INFRO Editorial

Published

7 min read

A glowing autonomous agent core coordinating tools, memory, and multiple AI model routes

In short

Every provider bills an image as input tokens at the model's normal input rate; the work is in predicting the token count. OpenAI derives it from resized image patches and a detail level, Gemini from a fixed per-setting table, and for Claude you should measure rather than assume.24

Key takeaways

  • An image has no price of its own on these APIs: it is input tokens at the model's input rate, so cost is token count times rate.
  • Gemini 4 and 3 models map a media_resolution setting to a fixed image token count (280, 560, 1120, or 2240 for ultra_high), so the setting, not the pixel size, drives cost.
  • OpenAI's calculator derives tokens from the resized image and a detail level, and rejects images over 30,000 patches, so client-side resizing and the detail choice are the levers.
  • For Claude, the hard limits are documented (8000x8000 px, 3,000 px when a request has more than 20 images), but measure the per-image token count on your own images before forecasting.
  • Forecast per screenshot and per page from a measured token count per class of image, then reconcile against recorded usage.

An image is input tokens, so cost is count times rate

None of the three vendors' pages I read gives an image its own price. OpenAI says images count as tokens and are billed accordingly.1 Its calculator estimates one image at standard input rates and excludes other prompt tokens, output, caching, long-context pricing and data-residency adjustments.2 Gemini's pricing table lists input per million tokens, and its media resolution page maps images to token counts.34

So the forecast is two numbers: tokens per image, and the input rate of the model you call. The rate is on a price page. The token count is where providers differ, and where a screenshot pipeline can drift by a factor of eight without any code change. This post covers the count; the count tokens before the API call post covers text.

How each provider turns an image into a count

ProviderWhat sets the countWhat I could confirm
OpenAIResized image dimensions, in patches, plus a detail level (auto, high, original appear in the docs)Images over 30,000 patches are rejected; a 6000 x 6000 image on gpt-6-astra is 35,344 patches at original and 2,500 at high2
AnthropicImage dimensions, within documented limitsMax 8000 x 8000 px per image; 100 images per request on 200k-context models, 600 on others; 3,000 px advised above 20 images5
GeminiThe media_resolution setting, per content item on Gemini 4 and 3Image: 280 (low), 560 (medium), 1120 (high and default), 2240 (ultra_high)4
what the pages I read confirm about image token counts.

Gemini is the simplest to forecast: the table is per setting, so a 600 px thumbnail and a 4000 px photo cost the same at the same setting. OpenAI is the most dimension-sensitive. For Anthropic, the vision page's per-image token formula was beyond what the fetch returned, so treat any number you read elsewhere as unverified until you measure it.

OpenAI: patches, detail and the 30,000 limit

The calculator's own example is the useful part. A 6000 x 6000 image exceeds the limit at original detail with 35,344 patches, but fits after resizing at high with 2,500 patches, and OpenAI's advice is to choose high only when the task does not need original resolution or precise image coordinates.2

The two patch counts are consistent with 32-pixel patches (188 x 188 = 35,344) and a 2,500-patch ceiling at high (50 x 50). That is my inference from the numbers, not a quoted rule, and the model-specific details live behind the calculator's "Calculation details" panel. Use it as the source of truth and keep the formula in your code as a check, not as the authority.

Two practical consequences follow. First, at original, the count rises with image area until you hit the rejection limit, so a pipeline that accepts user uploads needs a size gate. Second, the same screenshot can have a very different token count depending on whether your code sets detail or leaves it on auto, so log which one you sent.

Gemini: set the resolution, not the pixel size

Gemini 4 and Gemini 3 models accept a resolution per content item, and you can mix levels in one request: high for a complex diagram, low for a contextual image.4 The documented image counts are 280, 560, 1120 and 2240 tokens, and unspecified (the default) gives 1120.4 Google says high is the optimal setting for most use cases, and reserves ultra_high for specific cases such as computer use, where testing shows a clear gain.4

Two details matter for spend. Because the default is 1120, a pipeline that never sets resolution is already paying the high count for every image, including thumbnails. And PDFs behave differently: the default is 560 per page, the recommended setting is medium at 560 plus native text, and Google notes quality typically saturates at medium and that high rarely improves OCR for standard documents.4 One non-token limit to design around: inline image data caps the total request (prompt, system instructions and inline bytes) at 20MB, and larger requests should use the File API.6

Rates changed today. The Gemini 4 Carbon and Argon standard input price was $2.00 per million tokens through 30 November 2026 and is $4.00 from 1 December; Neon is listed at $3.00.3 See the price-doubling re-forecast for the budget side. The pricing table I read has a single input row; it does not say image tokens are priced differently from text, so I treat them as the same rate.

Per-screenshot and per-page arithmetic

Cost per image is tokens x rate / 1,000,000. The Gemini rows below use the documented token counts and the $4.00 rate listed above for Carbon and Argon from 1 December.43

The PDF row shows why the unit matters. Sending a scan as a PDF at medium and as page images at high can differ by 2x for the same pages, and the PDF path also adds native text, so measure both on your own documents before choosing.

For OpenAI and Anthropic, substitute a measured count and your own rate:

image_cost.py
import math

def patches(w: int, h: int, patch: int = 32) -> int:
    # 32 px is inferred from OpenAI's published example counts; verify
    # against the calculator before relying on it.
    return math.ceil(w / patch) * math.ceil(h / patch)

def image_cost(tokens: int, usd_per_mtok: float) -> float:
    return tokens * usd_per_mtok / 1_000_000

# 6000x6000 -> 35,344 patches, matching OpenAI's published example
assert patches(6000, 6000) == 35_344

def monthly(images_per_day: int, tokens: int, usd_per_mtok: float) -> float:
    return images_per_day * 30 * image_cost(tokens, usd_per_mtok)

Resize rules that actually move the count

Which rule helps depends on the provider, so write them down per route rather than one global thumbnail step.

  1. Gemini: change resolution, not pixels. Resizing does not change the documented token count at a given setting. Set low or medium per item for screenshots where layout, not small text, is the question, and keep high for dense charts.4
  2. OpenAI: cap dimensions before upload. Count grows with dimensions, and over 30,000 patches the request is rejected.2 Pick a maximum edge per image class, and use high rather than original unless you need original resolution or precise coordinates.
  3. Anthropic: stay inside the limits, then measure. Resize to no more than 3,000 px a side if a request may carry more than 20 images, because a stricter per-image limit applies to every image in such a request, including resent history and screenshots inside tool results.5 Beyond that, test whether a smaller edge changes your measured count and your accuracy.
  4. Crop before you shrink. A cropped region of interest keeps text legible at a smaller size than a whole-page downscale. This is a general engineering point, not a vendor claim.
  5. Gate on accuracy, not only cost. Google's own guidance is to test each resolution against your application, and the same holds for any shrink.4

Repeated images and long threads

Agent loops that return a screenshot every step multiply the image count, and on Anthropic every image in the request counts, including those from earlier turns and tool results.5 Anthropic recommends the Files API so base64 bytes are not resent each turn, which shrinks the payload and latency.5 That is a request-size fix. For token cost, check whether the image sits in a cached prefix: cache reads are 0.1x the base input price on most Claude models and 0.05x on Opus 5.5 and Sonnet 5.5.7 I did not confirm that images qualify for cache hits, so read the cache fields in your response usage before you forecast on them. See prompt caching across providers.

Also note the model's rate varies far more than the image count does. Anthropic's page lists Haiku 5.5 at $0.10 per million input tokens for prompts up to 100,000 tokens, and Fable 5.2 at $8, so the same measured image can differ by an order of magnitude in cost between tiers.7

Forecast, then check against what was billed

A workable method: sample 50 to 100 real images per class (screenshot, scan, photo), record the token count the provider reports for each, take the median and the 90th percentile, and multiply by volume and your contracted rate. Re-run after changing the model, the detail or resolution setting, or the resize step, because each can change the count without an error.

If your requests go through INFRO, the request log records token or unit counts and estimated provider cost per request, so you can compare the measured count per image class with the forecast. Negotiated rates can be entered so the estimate uses them, and routing rules can match on requests that carry images, which lets you send screenshot traffic to a different target than text. The reported counts are the provider's; INFRO adds no image charge on top of what your provider bills.

Questions readers ask

Does image file size in megabytes change the token count?
The pages read tie tokens to dimensions (OpenAI's calculator takes width and height) or to a resolution setting (Gemini). File size matters for request limits, such as Gemini's 20MB cap on inline request size. It is not an input to the OpenAI calculator.
Should I upload images once and reference them by ID to cut cost?
It shrinks request payloads, not the tokens the model reads. Anthropic's documentation recommends its Files API so base64 bytes are not resent on every turn, and describes the benefit as smaller requests and lower latency. Token billing for a re-referenced image is a separate question to check on your own usage records.

From the team that builds it

Where this shows up in INFRO

INFRO is a control plane in front of the provider accounts you already hold. The capabilities below are the parts of it this article touches, each with the documentation that defines its behaviour.

  • Usage and cost per request

    Available with a plan

    Every request records its model, latency, token or unit counts, and estimated provider cost, queryable by project and key.

    Read the documentation for Usage and cost per request
  • Routing rules

    Available with a plan

    If-rules on a route send matching requests to their own targets, by metadata, feature, end user, key, project, prompt size, streaming, images, tools or time of day. Failure rules decide per failure kind whether to retry, move on or stop.

    Read the documentation for Routing rules
  • Negotiated provider rates

    Available with a plan

    Enter the rates your contracts actually carry, per model and optionally per provider, so estimated cost uses them before the vendor's list rate. Included on every plan.

    Read the documentation for Negotiated provider rates

INFRO accounts are self-serve. Provider usage is billed to you by your providers; INFRO charges a software subscription and takes 0% of model spend. See plans.

Sources

Numbered in order of first citation. Each was opened and checked against the claim on the date shown.

  1. 1.Images and vision (opens in a new tab) — OpenAI. Accessed Dec 1, 2026.
  2. 2.Image input token and cost calculator (opens in a new tab) — OpenAI. Accessed Dec 1, 2026.
  3. 3.Gemini Developer API pricing (opens in a new tab) — Google. Accessed Dec 1, 2026.
  4. 4.Media resolution (opens in a new tab) — Google. Accessed Dec 1, 2026.
  5. 5.Vision (opens in a new tab) — Anthropic. Accessed Dec 1, 2026.
  6. 6.Image understanding (opens in a new tab) — Google. Accessed Dec 1, 2026.
  7. 7.Pricing (opens in a new tab) — Anthropic. Accessed Dec 1, 2026.

About this article

Read on 1 December 2026: OpenAI's images and vision guide and image cost calculator, Anthropic's vision and pricing pages, and Google's media resolution, image understanding and pricing pages. The OpenAI guide's cost-calculation section and Anthropic's per-image token formula were cut off in what was returned, so neither is quoted; no OpenAI rates were read, so dollar figures for OpenAI and Claude images are marked illustrative.

Last checked against its sources on . The next review is due by . No separate named reviewer is recorded for this article.

How articles are written, sourced and corrected is set out in the editorial standards.