[BUG] MCP ImageContent in tool results is collapsed by default in claude.ai web / Claude Desktop (image not displayed inline)

Resolved 💬 2 comments Opened Apr 25, 2026 by shigechika Closed Apr 29, 2026

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?

Note: This is a Claude Desktop / claude.ai web UI bug, not Claude Code CLI. Filing here following the precedent of #22451 and #32479.

When an MCP server returns ImageContent (e.g., a chart from a charting tool), the claude.ai web app (Desktop) renders the entire MCP tool call block — Request parameters JSON + Response image — collapsed by default behind a ▶ expander. The image is hidden from the user until they manually click to expand the block.

In contrast, Anthropic's built-in image_search tool returns images that display inline immediately without folding.

What Should Happen?

MCP tool results that contain ImageContent should render the image inline by default, like image_search does. Folding the whole Request+Response block hides what is often the primary deliverable of the tool call (a chart, screenshot, diagram, etc.).

Error Messages/Logs

N/A — no error; the image is delivered correctly to the model and the UI, but is hidden behind a collapse expander.

Steps to Reproduce

  1. Set up an MCP server that returns ImageContent (e.g., FastMCP Image(...) return value, jupyter-mcp-server, playwright MCP, etc.)
  2. Connect via Streamable HTTP connector in claude.ai web (Settings → Connectors → Add custom connector)
  3. Invoke the tool from a chat (e.g., "render a candlestick chart for code 7203")
  4. Observe: the tool call block is folded by default; user must click ▶ to see the image

Claude Model

Not sure / Multiple models (the bug is in UI rendering, model-independent)

Is this a regression?

I don't know

Last Working Version

N/A

Claude Code Version

N/A — this is a Claude Desktop / claude.ai web bug, not Claude Code CLI.

Claude Desktop version: Claude 1.4758.0 (fb266c) 2026-04-24T20:22:30.000Z

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Other (this is a Claude Desktop / claude.ai web UI bug, terminal not applicable)

Additional Information

Server-side verification — confirmed FastMCP returns the minimal, purest possible ImageContent:

Tested with FastMCP 3.2.2:

  • ToolResult.content = [ImageContent] (1 element only)
  • ToolResult.structured_content = None
  • ToolResult.meta = None
  • Tool.output_schema = None
  • to_mcp_result() returns list[ImageContent] with 1 element (no CallToolResult wrap, no structuredContent, no meta)

FastMCP source (tools/base.py:124-137):

def to_mcp_result(self):
    if self.meta is not None:
        return CallToolResult(...)
    if self.structured_content is None:
        return self.content  # ← this branch is taken
    return self.content, self.structured_content

→ The server hands the MCP transport the most minimal possible response (one ImageContent, no extras). The folding behavior is purely client-side (claude.ai web UI).

Connection details:

  • Client: claude.ai web (Claude Desktop app), Streamable HTTP connector
  • Server: custom OSS MCP server (https://jquants-mcp.aikawa.jp/mcp)
  • Reproduction repo: https://github.com/shigechika/jquants-mcp (render_candlestick tool, returns Image(...))

Impact:

  • Charting / screenshot / diagram MCP tools become impractical (users click to see every output)
  • Model's narrative loses visual context (the model receives the image, but the user doesn't see it inline)

Related issues:

  • #31208 (CLI-side: MCP ImageContent treated as text in tool results, 10-20x token waste) — different bug, same root cause: MCP ImageContent handling lags image_search parity
  • #45575 (CLI TUI: text hidden when structuredContent exists) — analogous "MCP content rendering inconsistency"
  • #22451, #32479, #40102 (precedent: Desktop bugs filed in claude-code repo)

View original on GitHub ↗

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