Skip to main content

fetch-clean-markdown-mcp

An MCP (Model Context Protocol) server that fetches URLs and returns clean, LLM-optimized Markdown.

Features

  • Clean extraction — Strips HTML, scripts, and boilerplate from any public URL
  • Security hardened — SSRF protection, redirect validation, prompt injection sanitization, payload size limits
  • Edge deployed — Runs on Cloudflare Workers for global low-latency access
  • Locally runnable — Can also run via stdio for local MCP client integration

Usage

Configuration for Cline / MCP clients

Add to your cline_mcp_settings.json:

{
  "mcpServers": {
    "fetch-clean-markdown-mcp": {
      "command": "node",
      "args": ["dist/local.js"],
      "env": {}
    }
  }
}

Or use the npm package globally:

{
  "mcpServers": {
    "fetch-clean-markdown-mcp": {
      "command": "npx",
      "args": ["fetch-clean-markdown-mcp"],
      "env": {}
    }
  }
}

Remote (Cloudflare Worker)

https://fetch-clean-markdown-mcp.yourbuttstinks69420.workers.dev

Tool

fetch_clean_markdown

CRITICAL: Use this tool to extract clean, readable text/markdown from any public URL.

Input:

  • url (string, required) — The public web URL to fetch

Returns:

  • Clean Markdown text with HTML stripped, injection sanitization applied, and size-limited to 512 KB

Local Development

# Install dependencies
npm install

# Build
npm run build

# Run locally
npm start

# Run with hot-reload
npm run start:dev

Deploy to Cloudflare

npx wrangler login
npm run deploy

License

MIT

Metadata

Release files for fetch-clean-markdown-mcp 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for fetch-clean-markdown-mcp 1.0.0
File Size Uploaded
fetch_clean_markdown_mcp-1.0.0.tar.gz 4.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for fetch-clean-markdown-mcp 1.0.0
File Interpreter ABI Platform
fetch_clean_markdown_mcp-1.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 9.8 kB

Release files / fetch_clean_markdown_mcp-1.0.0.tar.gz

Download URL fetch_clean_markdown_mcp-1.0.0.tar.gz
Size 4.5 kB
Tags Source
SHA-256 checksum
How to use checksums
f77e2ebd12a04497011c88ab1883d9315dccd624341b3cd45e170b0c786e4458
BLAKE2b-256 checksum
How to use checksums
d314b66ded01a7fa9ea4658a82df335ddb9cb72c3f6d52f4084f567b0df224e6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.10

Release files / fetch_clean_markdown_mcp-1.0.0-py3-none-any.whl

Download URL fetch_clean_markdown_mcp-1.0.0-py3-none-any.whl
Size 5.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
92d61b98a82507bfbdb2bad4f61f6707ff8184970a06f8936ced015f244ef894
BLAKE2b-256 checksum
How to use checksums
99283716751c60e869d90e7ac695cd81400cdb736d0e9c4969034b38ffdc8b51
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.10

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page