MCP

MarkItDown MCP troubleshooting

Updated 2026-11-16·Upstream source ↗
Markdown view

Most MCP problems are one of a handful of things, and we reproduced each of them below with the exact message. Start by running the server on its own: if it does not start there, no client will make it start.

Short answer

Run the command from your config in a terminal. If it starts and waits, the server is fine and the problem is the client's config or path. If it prints an error, fix that first.

Tested with markitdown 0.1.9 · Python markitdown-mcp 0.0.1a8, MCP SDK 2.3.0, Python 3.13, Linux lab; Claude Code 2.1.325, Codex CLI 0.169.0, Gemini CLI 0.68.0 (T13, T21) · 2026-11-16 · evidence: server-probe.log, uvx-probe.log, cc-probe.log, mcp.log

The client says "failed to connect" or CONNECTION_CLOSED

Claude Code reported Failed to connect — CONNECTION_CLOSED for uvx markitdown-mcp==0.0.1a8 under uv 0.11.32. Running the command shows the cause:

uvx with the pinned server
$ uv --version
uv 0.11.32 (x86_64-unknown-linux-gnu)
$ uvx markitdown-mcp --help   (uv 0.11.32)
               than STDIO (default: False)
  --sse        (Deprecated) An alias for --http (default: False)
  --host HOST  Host to bind to (default: 127.0.0.1)
  --port PORT  Port to listen on (default: 3001)
$ uvx --from markitdown-mcp markitdown-mcp  resolved versions
markitdown-mcp 0.0.1a7 markitdown 0.1.5
$ uvx --prerelease=allow ...
markitdown-mcp 0.0.1a8 markitdown 0.1.9
$ uvx markitdown-mcp==0.0.1a8 --help   (uv 0.11.32)
uvx-probe.log · 1,205 bytes · first 12 of 23 lines shown output (.md)

The server depends on a pre-release package, so uv needs --prerelease=allow. With the flag it connected:

Command
uvx --prerelease=allow markitdown-mcp==0.0.1a8

A plain uvx markitdown-mcp started under the same uv but silently resolved the older 0.0.1a7 with markitdown 0.1.5. Check the version with pip show markitdown-mcp: the server has no --version flag.

Unsupported URI scheme

The tool takes a URI. A plain path such as /tmp/report.docx was rejected with Unsupported URI scheme: /tmp/report.docx. Supported schemes are: .... Use file:///tmp/report.docx, http(s)://... or a data: URI. An empty URI gave the same error.

Short error messages

Every error the server returned in our probe
What we askedMessage length
missing file97
a folder86
a plain path without a scheme143
empty uri118
https to an unreachable host71
Every error the server returned in our probe Source: Test T13 · markitdown-mcp 0.0.1a8 · mcp-responses.csv · Download CSV

A missing file gave "Could not read the resource: No such file or directory", a folder "Is a directory", and an unreachable address "Could not fetch the resource." The nested cause is not included.

An empty result with no error

A scanned PDF returned 0 characters (OCR). The server cannot read text from pictures.

A huge document

A 200-page text PDF came back as 848,539 characters, roughly 212,000 tokens. A client with a tool-result limit may refuse that. We did not reproduce a client's limit message. Convert with the command line instead and let the client read the file (CLI).

The server stops answering with plugins enabled

With MARKITDOWN_ENABLE_PLUGINS=true and the upstream sample plugin, a request for an RTF file with an emoji in it never returned: the plugin's output contained lone surrogate characters and the server died with UnicodeEncodeError ... surrogates not allowed (details). Turn plugins off for the server, or use a plugin whose output is valid text.

HTTP mode

markitdown-mcp --http listens on 127.0.0.1:3001. The endpoint is /mcp: /mcp/ redirected (307) and / gave 404. Starting it on another interface printed a warning that the server has no authentication.

Client-specific traps we hit

  • Claude Code: put --env KEY=value after the server name.
  • Codex CLI: CODEX_HOME must point at an existing folder.
  • Gemini CLI: project-scope servers are disabled in an untrusted folder.

See the client page.

Messages reported upstream that we did not reproduce

These need a client or a server version we did not run. Their cards say so.

Input should be 'tools/call'

Not yet tested · fixed in 0.0.1a7

Input should be 'tools/call'

markitdown-mcp 0.0.1a4 pins an old MCP SDK that does not understand newer clients.

Fix

  • Use markitdown-mcp 0.0.1a7 or newer (0.0.1a8 is current).

Affected: 0.0.1a4 · Upstream report

Field required

Not yet tested

Field required [type=missing, input_value={}, input_type=dict]

The URI was sent under params.input; the tool expects params.arguments.

Fix

  • Send {"name": "convert_to_markdown", "arguments": {"uri": "file:///..."}}.

Affected: any · Upstream report

SseError: fetch failed in Docker

Not yet tested

SseError: SSE error: TypeError: fetch failed: other side closed

The server inside the container listens on 127.0.0.1, which the host cannot reach.

Fix

  • Start the server with --host 0.0.0.0 inside the container and publish the port (-p 3001:3001); see the security warning for non-local binds.

Affected: Docker · Upstream report

In our Docker run the HTTP endpoint was /mcp and answered normally when the port was published (Docker page).