◉CLAUDE LABJP
●2.1.301 — Adds the vim % motion, LaTeX math rendering in the VS Code panel, and a retry-watchdog limit for usage-limit waits (10/15)●2.1.299 — Conversations over 200K tokens left idle about 54 minutes get compacted; MCP allow rules now match only the server they name●SONNET 4.5 — Retires on the Claude API on 11/30, 45 days left. Migrate to Sonnet 5.5●WINDOWS — Reports say hooks break silently only on Japanese-locale Windows; check the character encoding first●FAST MODE — Opus 5.5 fast mode is out of research preview and no longer needs the beta header (10/15)●NEW — I Put a Ten-Line Promise File at the To…●2.1.301 — Adds the vim % motion, LaTeX math rendering in the VS Code panel, and a retry-watchdog limit for usage-limit waits (10/15)●2.1.299 — Conversations over 200K tokens left idle about 54 minutes get compacted; MCP allow rules now match only the server they name●SONNET 4.5 — Retires on the Claude API on 11/30, 45 days left. Migrate to Sonnet 5.5●WINDOWS — Reports say hooks break silently only on Japanese-locale Windows; check the character encoding first●FAST MODE — Opus 5.5 fast mode is out of research preview and no longer needs the beta header (10/15)●NEW — I Put a Ten-Line Promise File at the To…
Articles/API & SDK
⬡ API & SDK/2026-07-13Advanced

Full-Size or Downscaled? A Per-Image Resolution Rule for Opus 4.7's High-Resolution Vision

Opus 4.7 finally read the fine texture in my wallpapers, so I sent everything at full size. My weekly image tokens jumped 2.4x. Here is the preflight that decides resolution and model per image, with the measured savings.

Claude API128Vision4Cost DesignIndie Dev23Opus 4.7

✦ Premium Article

When I moved the auto-tagging pipeline for my Dolice wallpaper apps over to Opus 4.7 — released in July 2026 with its stronger high-resolution vision — I could suddenly feel it picking up the fine stuff: the gradients in traditional Japanese patterns, the thin lines in ukiyo-e prints.

Delighted, I started sending every image through at full size. The next week I looked at the input-token bill and stopped. Accuracy really had improved, but the image-input tokens alone had swollen to roughly 2.4x the prior week.

"Just downscale everything" was not the answer either. Splitting landscape from portrait is fine at 512px, but the moment I needed to tell two near-duplicate wallpapers apart, or read small text inside a sample UI image, downscaling broke the result. What I needed was neither "shrink everything" nor "send everything full-size," but a rule that decides, per image, how much resolution that particular image actually demands.

Here is how I built that decision rule, and how much it cut my weekly cost.

Image tokens are set by area — downscaling tunes information, not just cost

The first thing worth internalizing: the tokens Claude bills for an image are driven almost entirely by pixel area. The documented estimate is:

input tokens ≈ (width px × height px) ÷ 750

Images whose long edge exceeds 1568px, or that exceed roughly 1.15M pixels, are downscaled by the API before processing. So past a certain size, sending full-size buys you no extra tokens billed — it just wastes upload bandwidth while the tokens flatten out.

Below are the approximate input tokens per resolution tier that I measured with count_tokens in my wallpaper pipeline. The formula is only an estimate, so in production I strongly recommend measuring with the count_tokens endpoint — it drifts by tens of tokens.

Long edge sentApprox. pixelsInput tokens (measured)Input cost per 10k images (Sonnet 5 intro $2/M)
384px~150k~200~$4.0
512px~260k~350~$7.0
768px~590k~790~$15.8
1024px~1.05M~1,400~$28.0
Near the cap (~1.15M px)~1.15M~1,540~$30.8

Building the table is what made it click for me: 384px versus 1024px is a 7x cost difference per 10k images. Sending everything full-size meant I was paying the most expensive row even to classify a landscape. Downscaling stopped feeling like a quality compromise and started feeling like what it is — dropping resolution down to the information the decision actually needs.

One trap: if you accidentally stuff an image into a text field as a base64 string, this area-based billing does not apply and you burn an order of magnitude more tokens. Everything here assumes you pass images as image blocks. I dug into that failure mode in saving tokens with tool-result image blocks.

Where downscaling helps, and where it breaks

Whether you can drop resolution depends on which grain of the image the task is reading. When I sorted my 30 wallpaper categories into "survives downscaling" and "doesn't," they split cleanly into two layers.

The labels that tolerate 512px were the ones looking at overall composition or theme. Landscape, portrait, abstract, seasonal — Opus 4.7 nails those even at 384–512px. In some cases downscaling actually stabilized the result by removing noise.

The labels that need full size were the ones where a fine difference decides the answer. Three cases in particular:

Kind of decisionWhat downscaling causesLong edge needed
Fine texture (patterns, gradients, grain effects)Texture collapses and gets mislabeled as "solid color"1024px+
Near-duplicate detection (two almost-identical images)The difference disappears; distinct images called "same"1024px+
Small text inside the image (sample UI, logos)Text becomes unreadable; content misreadNear the cap

Opus 4.7's high-resolution improvement pays off precisely in this lower layer. With the previous model, fine texture was shaky even at full size; with 4.7, hand it full resolution and it reads it reliably. Which is the whole point: pay for full size only on the images that benefit from high-resolution vision, and downscale the rest. That line is the backbone of the decision rule.

✦

Thank you for reading this far.

Continue Reading

What follows includes implementation code, benchmarks, and practical content we hope you'll find useful. This site runs without ads — server and development costs are supported entirely by members like you. If it's been helpful, we'd be truly grateful for your support.

WHAT YOU'LL LEARN
✦Image tokens scale with pixel area and flatten near a 1568px long edge and ~1.15M pixels — why you should measure with count_tokens instead of trusting the formula
✦Coarse labels survive downscaling; fine texture and small text need full size. Where downscaling quietly destroys accuracy
✦A two-stage ladder that classifies downscaled first and escalates to full-size plus Opus 4.7 only when needed, with working Python and a week of real numbers
Secure payment via Stripe · Cancel anytime
✦

Unlock This Article

Get full access to the rest of this article. Buy once, read anytime. This site is ad-free — your support goes directly toward keeping it running.

or
Unlock all articles with Membership →
Share

Thank You for Reading

Claude Lab is ad-free, supported entirely by members like you. We publish practical guides daily with implementation code, benchmarks, and production-ready patterns. If you've found it useful, we'd love to have you on board.

  • ✦Copy-paste ready implementation code
  • ✦New advanced guides published daily
  • ✦$5/mo or $10 for lifetime access
View Membership →

Related Articles

⬡ API & SDK2026-09-17
I Send Images Twenty at a Time — The Day the 21st Image Changed the Rules for the Other 61
Sending 62 images in one request failed with invalid_request_error. The cause was the image count, not the payload size. Here is how I recounted visual tokens as 28px patches and built batches that respect count, dimensions, and payload at once.
⬡ API & SDK2026-05-15
Automating Wallpaper Classification with Claude Vision API — Accuracy, Cost, and a Batch Job That Survives Interruptions
A firsthand account of automating wallpaper category classification with the Claude Vision API. Honest numbers on accuracy and cost, plus the batch design that stopped me re-paying for the same images.
⬡ API & SDK2026-04-26
Building a Hard-to-Cancel Micro-SaaS with the Claude API — Six Implementation Patterns to Stabilize $1,000/Month
Hitting $1,000/month with a Claude-powered micro-SaaS is one challenge. Holding it for three months running is a much harder one. Here are six implementation patterns — with working Stripe and Cloudflare Workers code — that took my churn from above 10% to under 5%.