Registry / http-networking / mcp-fetch-server

mcp-fetch-server

JSON →
library0.1.9jsnpmunverified

MCP server and CLI for fetching web content as HTML, Markdown, plain text, JSON, or YouTube transcripts. Current stable version 1.1.2, released regularly on npm. Key differentiators: multiple output formats, Mozilla Readability integration for article extraction, YouTube transcript support via yt-dlp or direct page extraction, and proxy support. Minimal configuration, designed for MCP ecosystem but also usable as standalone CLI. Requires Node.js >=18.

npm install mcp-fetch-server
INSTALL
IMPORT
SIG · MCP-FETCH-SERVER
M
mcp-fetch-server
http-networkingjavascriptv0.1.9
Install
Import
Disk
Pass rate
0/ 6
Env Coverage0 / 6
glibc
1822
musl
1822
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18226 runs
build_error
glibc
node 18226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

mcp-fetch-server
npx mcp-fetch-server (CLI) or add to MCP configuration as a tool (no programmatic import)
require('mcp-fetch-server') or import from 'mcp-fetch-server' as a module
This package is a CLI/MCP server; there is no exported JavaScript module to import. Use via npx or install globally.

Shows how to add the MCP server to client config and run CLI commands for markdown and YouTube transcript.

// Add to your Claude Desktop or MCP client config: { "mcpServers": { "fetch": { "command": "npx", "args": ["mcp-fetch-server"] } } } // Or use as CLI: npx mcp-fetch markdown https://example.com --max-length 10000 npx mcp-fetch youtube https://www.youtube.com/watch?v=dQw4w9WgXcQ --lang es
mcp-fetch --version
Debug
Known issues
gotchaThe package does not export any programmatic API; it is designed to be used via command line or as an MCP server. Attempting to require() or import it in Node.js will result in an error.
fix
Use npx mcp-fetch-server to run as MCP server, or use CLI commands. If you need a fetch function programmatically, use libraries like undici or node-fetch directly.
affects: >=1.0.0
gotchaYouTube transcript extraction may fail if yt-dlp is not installed and the direct page extraction method encounters issues (e.g., non-standard player, captions not accessible). The tool falls back silently but may return empty output.
fix
Install yt-dlp globally (pip install yt-dlp) for more reliable transcript fetching.
affects: >=1.0.0
gotchafetch_readable uses Mozilla Readability which may not work well on non-article pages (e.g., homepage, video pages). It may return incomplete content or empty string.
fix
Use fetch_html or fetch_markdown for non-article pages; fetch_readable is designed for blog posts and articles.
affects: >=1.0.0
gotchaDefault max_length is 5000 characters, which may truncate content unexpectedly for large pages. Setting DEFAULT_LIMIT=0 can return full content but may cause memory issues for very large pages.
fix
Set max_length parameter appropriately per request, or configure DEFAULT_LIMIT environment variable to a higher value or 0 for no limit (with caution).
affects: >=1.0.0
deprecatedThe package may change its tool names or parameters in future releases as the MCP specification evolves. Check changelog when upgrading.
fix
Keep up-to-date with the MCP specification and package changelog on GitHub: https://github.com/zcaceres/fetch-mcp
affects: >=1.0.0
Errors
Common errors & fixes
npx mcp-fetch-server: command not found
Node.js version is below 18 or npm not installed.
fix
Install Node.js >=18 and ensure npm is up to date. Run: node --version && npm --version
Error: Cannot find module 'mcp-fetch-server'
Attempting to import the package programmatically (require('mcp-fetch-server')) instead of using CLI/MCP server.
fix
Do not try to import this package in code. Use npx mcp-fetch-server to run it as an MCP server, or use CLI commands directly.
Failed to fetch YouTube transcript: no captions found
Video does not have captions in the requested language, or yt-dlp is missing and direct extraction failed.
fix
Try a different language code (--lang). Install yt-dlp globally for better extraction: pip install yt-dlp
Error: read ECONNRESET
Network issues, proxy misconfiguration, or target server blocking the request.
fix
Check network connectivity. If using a proxy, verify proxy URL. Try a different URL. Consider adding custom headers to simulate a browser User-Agent.
Upgrade
Version history
0.1.9latest on npm
Audit
Dependencies
mozilla/readabilityrequiredUsed for fetch_readable tool to extract article content
jsdomrequiredUsed to parse HTML and extract plain text / markdown
turndownrequiredConverts HTML to Markdown for fetch_markdown tool
yt-dlpoptionalOptional binary used for fetching YouTube transcripts; falls back to direct page extraction if not available
Agent activity
4 hits · last 30 days
node
4
Resources