Fetch MCP Server
Fetches web content and converts it to LLM-friendly formats. Retrieves web pages, API responses, and online documentation, converting HTML to clean markdown for efficient token usage and better comprehension.
MCP Server Configuration
{ "mcpServers": { "fetch": { "command": "npx", "args": ["-y", "@modelcontextprotocol/server-fetch"] } } }
With Custom User Agent
{ "mcpServers": { "fetch": { "command": "npx", "args": ["-y", "@modelcontextprotocol/server-fetch"], "env": { "USER_AGENT": "Claude-Code-Fetch/1.0" } } } }
Available Tools
| Tool | Description |
|---|---|
fetch | Fetch a URL and return content in LLM-friendly format |
Tool Parameters
{ "url": "string β The URL to fetch", "max_length": "integer (optional) β Maximum content length in characters", "start_index": "integer (optional) β Start reading from this character position", "raw": "boolean (optional) β Return raw content without markdown conversion" }
Example Usage
# Fetch a documentation page (auto-converts HTML to markdown)
fetch: { url: "https://docs.example.com/api/auth" }
# Fetch API response (JSON)
fetch: { url: "https://api.example.com/status", raw: true }
# Fetch with length limit (for large pages)
fetch: { url: "https://example.com/long-article", max_length: 5000 }
# Paginated reading of long content
fetch: { url: "https://example.com/docs", max_length: 5000, start_index: 0 }
fetch: { url: "https://example.com/docs", max_length: 5000, start_index: 5000 }
Setup
- Add the configuration to
.claude/settings.json - No API keys required
- Requires network access for fetching URLs
Use Cases
- Documentation lookup β Fetch library docs, API references, changelogs
- API responses β Check endpoint responses, verify API behavior
- Content extraction β Pull text from web pages for analysis
- Research β Read online articles, blog posts, release notes
Security Notes
- Respects
robots.txtby default - Follows redirects (up to a reasonable limit)
- Does not execute JavaScript β only fetches static content
- Be mindful of rate limiting on target sites
- Do not use to fetch pages requiring authentication (no cookie/session support)
- Content is processed locally β not stored or forwarded to third parties
Reviews
No reviews yet. Be the first to review this template!
Similar Templates
Database MCP Integration
MCP server configuration for connecting Claude Code to PostgreSQL, MySQL, and MongoDB databases. Enables schema inspection, query building, and migration generation.
Elevenlabs Server
Streamline your workflow with this official, elevenlabs, text, speech. Includes structured workflows, validation checks, and reusable patterns for audio.
Browser Use Portal
Powerful mcp for server, enables, agents, control. Includes structured workflows, validation checks, and reusable patterns for browser_automation.