NEWScrapingAnt MCP for Claude Code, Cursor & Windsurf — try it free →
Skip to main content

Fetch MCP Server: Setup, Limits and What to Use When It Fails

· 12 min read
Oleg Kulyk
Co-Founder @ ScrapingAnt

The Fetch MCP server is the reference server from the Model Context Protocol project that lets an AI assistant download a web page and read it as Markdown. It is free, runs locally with one command, and is the first web tool most people add to Claude Code or Claude Desktop.

It also has clear limits: it does not run JavaScript, it obeys robots.txt for model-initiated requests, and it uses its own user agent, which some sites refuse. This guide shows how to set it up, what each limit looks like in practice, and when a different tool fits better.

How the Fetch MCP server gets a page compared with a scraping API: Fetch sends one HTTP request from your machine and converts the HTML to Markdown, while a scraping API can render JavaScript in a browser and route the request through a proxy

Everything below was run on December 3, 2026 with mcp-server-fetch 2026.11.11 from PyPI (via uvx 0.13.7), the mcp/fetch Docker image, the MCP Python SDK 2.3.0 and Claude Code 2.1.330. Limits are quoted from the server's README or observed in these runs, and each is marked as one or the other. If you are new to MCP itself, start with what an MCP server is.

What is the Fetch MCP server?​

The Fetch MCP server is an open-source MCP server that exposes one tool, fetch, which downloads a URL and returns its content as Markdown. It lives in the modelcontextprotocol/servers repository and is published on PyPI as mcp-server-fetch.

Its fetch tool takes these arguments, according to the README:

ArgumentDefaultWhat it does
urlrequiredThe page to fetch
max_length5,000Maximum characters returned per call
start_index0Character offset to start from, for reading a page in chunks
rawfalseReturn the page without Markdown conversion
timeout_ms30,000HTTP timeout for this call, 100 to 600,000 ms

The server also offers a fetch prompt, which a user starts by hand. That difference matters for robots.txt and the user agent, as shown below.

How do I install the Fetch MCP server?​

The README recommends running it with uvx, which needs no separate install step. You can also install it with pip or run the mcp/fetch Docker image.

# uv (recommended by the README): downloads and runs it on demand
uvx mcp-server-fetch

# pip
pip install mcp-server-fetch
python -m mcp_server_fetch

# Docker
docker run -i --rm mcp/fetch

You do not run these by hand in normal use: your MCP client starts the command and talks to it over stdio. Running one in a terminal is a quick check that it starts.

One thing we noticed: on December 3, 2026, the mcp/fetch:latest Docker image contained version 0.6.3 of the server, while PyPI had 2026.11.11. The Docker build also had no Node.js, so it used the pure-Python HTML extractor and returned <p>Example Domain</p> where the uvx version returned # Example Domain. If output quality matters, prefer uvx or pip.

The README also notes that when Node.js is on your PATH, the server uses Mozilla's Readability.js for extraction and installs its npm dependencies on first use. Without Node.js, it falls back to a pure-Python extractor that "keeps headings and text but drops link targets".

How do I add the Fetch MCP server to Claude Code?​

Run one command; Claude Code writes the server into its MCP configuration.

claude mcp add fetch -- uvx mcp-server-fetch

With --scope project, the server goes into a .mcp.json file in the project folder that you can commit for your team. This is the file Claude Code 2.1.330 wrote in our test:

{
"mcpServers": {
"fetch": {
"type": "stdio",
"command": "uvx",
"args": ["mcp-server-fetch"],
"env": {}
}
}
}

Claude Code asks you to approve a project-scoped server the first time you start a session in that folder.

How do I add the Fetch MCP server to Claude Desktop and Cursor?​

Add a fetch entry to the client's mcpServers configuration with uvx as the command. The README gives this block for Claude Desktop's claude_desktop_config.json:

{
"mcpServers": {
"fetch": {
"command": "uvx",
"args": ["mcp-server-fetch"]
}
}
}

Cursor uses the same mcpServers format in .cursor/mcp.json for one project or ~/.cursor/mcp.json for all projects, according to Cursor's MCP documentation. Restart the client after editing the file. Options such as --ignore-robots-txt or --user-agent=... go at the end of the args list.

How long a page can the Fetch MCP server read?​

It returns at most 5,000 characters per call by default and tells the model how to get the rest. In our test on the Wikipedia article "Web scraping", the first call returned 5,000 characters of content and ended with this line:

<error>Content truncated. Call the fetch tool with a start_index of 5000 to get more content.</error>

A second call with "start_index": 5000 returned the next chunk, and "max_length": 20000 returned 20,000 characters in one call. That paging is a strength: the model reads only as much of a long article as it needs, and the Readability extraction removes navigation and sidebars first.

The README also sets a hard ceiling: the server reads at most 5 MiB of a response body and refuses anything larger with an error.

Can the Fetch MCP server read JavaScript-rendered pages?​

No. The server makes one HTTP request and converts the HTML it gets back; it does not run a browser, so content that JavaScript adds after load is missing. On the JavaScript version of quotes.toscrape.com, which draws its quotes with a script, this is the whole result:

Contents of https://quotes.toscrape.com/js/:
# Quotes to Scrape

[Login](/login)

* [Next](/js/page/2/)

The page has 10 quotes; the result has none, and the tool did not report an error. That silent gap is the risk: the model may tell you the page is empty instead of telling you it could not see it.

Why does the Fetch MCP server say robots.txt does not allow fetching?​

Because by default the server obeys robots.txt for every fetch the model starts, and refuses if the site's rules disallow the page for its user agent. Pages a user requests through the fetch prompt are not checked, according to the README.

Asking for a Google search results page gave this error in our run (trimmed):

Error executing tool fetch: The sites robots.txt (https://www.google.com/robots.txt), specifies that
autonomous fetching of this page is not allowed,
<useragent>ModelContextProtocol/1.0 (Autonomous; +https://github.com/modelcontextprotocol/servers)</useragent>
<url>https://www.google.com/search?q=web+scraping</url><robots>
User-agent: *
...

Two details from that run are worth knowing. The error includes the site's full robots.txt, so this one refusal put 13,126 characters into the model's context. And the README says a robots.txt that cannot be fetched, or that answers 401, 403 or 5xx, also makes the tool refuse the page.

The README documents --ignore-robots-txt to turn the check off. Before you use it, check that the site's terms allow automated access; robots.txt is how a site says what it does not want fetched.

Why does the Fetch MCP server get blocked?​

Sites with bot protection see a request from your own IP with an identifying user agent and no browser, and some answer with an error page or status code instead of the content. On a Walmart product page, the Fetch server returned this in our run:

Error executing tool fetch: Failed to fetch https://www.walmart.com/ip/6077911929 - status code 444

By default, the server identifies itself as ModelContextProtocol/1.0 (Autonomous; +https://github.com/modelcontextprotocol/servers) for model-initiated fetches, per the README. You can change it with --user-agent=... and route requests through your own proxy with --proxy-url (HTTP and SOCKS5 are supported). Neither adds JavaScript rendering, and neither gives you rotating IPs unless your proxy does.

What should I use when the Fetch MCP server fails?​

Pick the tool by the job, not by habit. Here is what fits each case:

Which MCP tool fits which page: the Fetch server for public static pages and long articles, a scraping MCP server with a browser for JavaScript pages and with proxies for blocked pages, a browser-automation MCP for clicking through flows, a search MCP for finding pages, and following links page by page to work through a site

  • Public, static pages and long articles: keep the Fetch server. It is free, fast (under 1.5 seconds per call in our runs) and its paging keeps long pages out of your context.
  • JavaScript-rendered pages and pages that block plain requests: use a scraping MCP server that can render with a browser and route through proxies, such as the ScrapingAnt MCP server.
  • Clicking, logging in, filling forms, multi-step flows: use a browser-automation MCP server such as Playwright MCP. Neither Fetch nor ScrapingAnt clicks through pages for you. See our guide to Playwright MCP with proxies.
  • Finding pages you do not have URLs for: use a search MCP server. Fetch and ScrapingAnt both need a URL.
  • Working through a whole site: ScrapingAnt's Markdown keeps the page's navigation and links, so an agent can find the next pages and call the tool once per page. The Fetch server's trimmed output keeps links inside the article but drops the site navigation. For very large sites, a dedicated crawler is the faster route.

How does the ScrapingAnt MCP server compare on the same pages?​

We sent the same URLs through the ScrapingAnt MCP server, which has three tools, get_web_page_html, get_web_page_markdown and get_web_page_text. Each takes url, browser (default true), proxy_type and proxy_country, per its documentation. Here is the side-by-side result:

Tested cases for the Fetch MCP server and the ScrapingAnt MCP server: both read a static page; Fetch returned a long article&#39;s trimmed body in 5,000-character chunks while ScrapingAnt returned the full 63,907-character page with its navigation and links; on a JavaScript page Fetch returned no quotes and ScrapingAnt with a browser returned all 10; on a Walmart product page Fetch got status 444 and ScrapingAnt returned the product name, price and rating

PageFetch MCP serverScrapingAnt MCP serverBetter here
Static page (example.com)Title and text, 0.5 sText, 1.2 s, 1 credit (browser: false)Fetch: same content, free
Long article (Wikipedia)Trimmed article body in 5,000-character chunks, with start_index pagingFull page with navigation and links in one response: 63,907 characters, 1 creditDepends: Fetch to read one article in parts, ScrapingAnt to see and follow links
JavaScript page (quotes.toscrape.com/js)No quotes, no errorAll 10 quotes with browser: true, 3.2 s, 10 creditsScrapingAnt
Protected page (Walmart product)status code 444Name, $134.00 price, was $149.00, 4.5 rating with browser: false, 3.1 s, 1 creditScrapingAnt

Two notes on that table. On the long article, the two servers do different jobs. Fetch trims the page to the article body and pages it in 5,000-character chunks, which suits reading one article. ScrapingAnt returns the whole page as Markdown in one response, navigation and links included, so an agent can see the links to other pages and follow them, calling the tool once per page to work through a site. And with browser: false, ScrapingAnt also returned no quotes from the JavaScript page; rendering is what makes the difference, and it costs 10 credits instead of 1.

The whole ScrapingAnt test above used 14 API credits.

How do I add the ScrapingAnt MCP server next to Fetch?​

Add it as a second server; you do not need to remove Fetch. In Claude Code:

claude mcp add --transport http scrapingant https://api.scrapingant.com/mcp

Then run /mcp in a session and choose Authenticate to sign in with your ScrapingAnt account, or pass your API key as a header instead:

claude mcp add --transport http scrapingant https://api.scrapingant.com/mcp -H "x-api-key: <YOUR-API-KEY>"

For Cursor and other clients, the MCP server documentation has the configuration for each. With both servers installed, you can tell the assistant which to use: "fetch this article" for a static page, and "get this page as Markdown with ScrapingAnt" for a JavaScript or protected page. Set browser: false for static pages to pay 1 credit instead of 10.

Is the Fetch MCP server safe to use?​

It is a read-only tool, but it can reach any URL your machine can, so treat it like any program that makes network requests for you. The README's caution notes and defaults are worth knowing:

  • It refuses private, loopback and link-local addresses, including cloud metadata endpoints such as 169.254.169.254, unless you add --allow-private-ips. The README says the check does not protect against DNS rebinding.
  • --allowed-hosts limits it to the hosts you list, for example "args": ["mcp-server-fetch", "--allowed-hosts", "docs.python.org", "*.wikipedia.org"].
  • Page content goes into the model's context, so a page can contain text written to steer the model. Review what an assistant does after reading untrusted pages.

Key takeaways​

  • The Fetch MCP server is the free, local default for reading public, static pages, and its 5,000-character paging works well for long articles.
  • It does not run JavaScript: on a script-rendered page it returned none of the content and no error.
  • It obeys robots.txt for model-initiated fetches, and its error includes the full robots.txt in the model's context.
  • Sites with bot protection can refuse it; a Walmart product page returned status 444.
  • For those two cases, a scraping MCP server with a browser and proxies filled the gap in our test; for clicking and searching, use a browser-automation or search tool instead. To work through a site, an agent can follow the links in ScrapingAnt's Markdown page by page.

To add the second case to your assistant, see the ScrapingAnt MCP server: the free plan includes 10,000 API credits a month.

Give your AI agent the live web

The ScrapingAnt MCP server lets Claude, Cursor and other MCP clients read any page as clean Markdown.