claude-code - 💡(How to fix) Fix Oversized pasted images fail at send with no preflight warning, no auto-resize, and aren't counted against context [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#52101Fetched 2026-04-23 07:36:34
View on GitHub
Comments
1
Participants
2
Timeline
5
Reactions
0
Timeline (top)
labeled ×4commented ×1

When a pasted image exceeds the Claude API's per-image dimension cap (2000px in many-image mode), the turn fails at send time with API Error: An image in the conversation exceeds the dimension limit for many-image requests (2000px). Start a new session with fewer images. This is surfaced only after the user has composed and submitted the turn, with no preflight warning, no auto-downscale, and no in-place edit path. The only recovery is Rewind, which is destructive.

It's especially confusing because the context window indicator shows plenty of headroom (e.g. 39% of 1M used), so from the user's perspective there is no visible reason the turn should fail. The dimension cap is a separate validation layer from context accounting and isn't exposed in the UI at all.

This is very easy to hit on macOS because Retina screenshots are captured at 2× logical resolution — a screenshot of most of the screen lands at 2880–3456px wide, well over the 2000px cap, without the user doing anything unusual.

Error Message

When a pasted image exceeds the Claude API's per-image dimension cap (2000px in many-image mode), the turn fails at send time with API Error: An image in the conversation exceeds the dimension limit for many-image requests (2000px). Start a new session with fewer images. This is surfaced only after the user has composed and submitted the turn, with no preflight warning, no auto-downscale, and no in-place edit path. The only recovery is Rewind, which is destructive. 4. Send. Turn fails with the 2000px error.

  1. Preflight validation on paste/attach. Check image dimensions client-side at the moment the image enters the composer, and either warn or offer to downscale before the user writes the turn.

Root Cause

This turns a silent platform constraint into a destructive, mid-conversation failure. The user loses composed text, loses trust in the context indicator ("why did it fail when I have 61% free?"), and has no local tooling path — the client should either prevent it, fix it transparently, or recover gracefully.

RAW_BUFFERClick to expand / collapse

Summary

When a pasted image exceeds the Claude API's per-image dimension cap (2000px in many-image mode), the turn fails at send time with API Error: An image in the conversation exceeds the dimension limit for many-image requests (2000px). Start a new session with fewer images. This is surfaced only after the user has composed and submitted the turn, with no preflight warning, no auto-downscale, and no in-place edit path. The only recovery is Rewind, which is destructive.

It's especially confusing because the context window indicator shows plenty of headroom (e.g. 39% of 1M used), so from the user's perspective there is no visible reason the turn should fail. The dimension cap is a separate validation layer from context accounting and isn't exposed in the UI at all.

This is very easy to hit on macOS because Retina screenshots are captured at 2× logical resolution — a screenshot of most of the screen lands at 2880–3456px wide, well over the 2000px cap, without the user doing anything unusual.

Repro

  1. On a Retina Mac, take a screenshot of a large portion of the screen (Cmd+Shift+4, drag across ~half the screen).
  2. Paste into Claude Code along with a text prompt.
  3. Have at least one prior image in the conversation (so many-image mode applies).
  4. Send. Turn fails with the 2000px error.

Expected

One of the following, in rough order of preference:

  1. Preflight validation on paste/attach. Check image dimensions client-side at the moment the image enters the composer, and either warn or offer to downscale before the user writes the turn.
  2. Auto-downscale on send. If an image exceeds the cap, resize it to fit (e.g. longest edge → 1800px) transparently. The model rarely benefits from >2000px anyway.
  3. Edit-in-place recovery. When the API rejects for this reason, let the user edit the failed turn (remove or resize the image) without losing the text they typed. Rewind discards the whole composition.
  4. Surface images in the context indicator. At minimum, show image count and per-image dimensions in the context tooltip so the limit is visible, not invisible until it fires.

Actual

  • No warning during composition.
  • Turn fails on send.
  • Text of the turn is stuck inside the failed bubble; the only way forward is Rewind, which discards it.
  • Nothing in the UI hints that image dimensions are a separate limit from context usage.

Environment

  • Claude Code desktop app
  • Model: Opus 4.7 (1M context)
  • macOS (Darwin 25.3.0)
  • Retina display (2× captures)

Why this matters

This turns a silent platform constraint into a destructive, mid-conversation failure. The user loses composed text, loses trust in the context indicator ("why did it fail when I have 61% free?"), and has no local tooling path — the client should either prevent it, fix it transparently, or recover gracefully.

extent analysis

TL;DR

Implement preflight validation on image paste to check dimensions and warn or offer to downscale before the user sends the turn.

Guidance

  • Check image dimensions client-side when an image is pasted into the composer to prevent turns from failing due to exceeding the 2000px dimension cap.
  • Consider auto-downscaling images to fit within the cap (e.g., longest edge → 1800px) to prevent failures without user intervention.
  • Provide an edit-in-place recovery option when the API rejects an image due to dimension limits, allowing users to resize or remove the image without losing composed text.
  • Display image count and per-image dimensions in the context tooltip to make the dimension limit visible to users.

Example

No code snippet is provided as the issue does not imply a specific code solution, but rather a design or implementation change to handle image dimensions.

Notes

The current implementation lacks a clear indication of the dimension limit, leading to user confusion and loss of composed text. Addressing this issue requires changes to the client-side validation, error handling, or UI to provide a better user experience.

Recommendation

Apply a workaround by implementing preflight validation on image paste, as this approach prevents turn failures and provides an opportunity to warn or downscale images before the user sends the turn, improving the overall user experience.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING