[BUG] Claude Code MCP - Image responses token exceeds 25000 tokens

Resolved 💬 3 comments Opened Oct 8, 2025 by nickyli98 Closed Oct 12, 2025

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Claude Code version - v2.0.10 - Sonnet 4.5

I'm trying to use this MCP - which responds an image with a data (below is a screenshot using MCP Inspector). The issue is that the length of the base 64 string exceeds the limit of 25,000

My understanding was that Claude treats images differently, and when i paste an image, even if the base64 length exceeds the 25k limit, but since it's an image - it has other limits. Is this an issue with Claude Code's MCP connector, or is my understanding incorrect?

<img width="566" height="431" alt="Image" src="https://github.com/user-attachments/assets/db413d29-8666-4da3-be17-f877be08b461" />

https://github.com/hangwin/mcp-chrome

  • I forked this, the extension here responds it as a text response, but as you can see from the screenshot, I modified it to respond the screenshot as an image content.

What Should Happen?

I expect an image response from MCP to be correctly processed, and the base64 string's length is ignored if it's an image, and processed as an image properly.

Error Messages/Logs

chrome-mcp - chrome_screenshot (MCP)(storeBase64: true, savePng: false, fullPage: true)
  ⎿  Error: MCP tool "chrome_screenshot" response (137411 tokens) exceeds maximum allowed tokens (25000). Please use pagination, filtering, or limit parameters to reduce the response size.`

Steps to Reproduce

Connect claude with an MCP tool that responds an image content, where base64 string length exceeds 25k tokens.
You should see the error iIshowed above.

Claude Model

Sonnet (default)

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.0.10

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

_No response_

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗