npm dompruner-mcpstreamable-httpMITupdated 10d ago
DOM AST middleware for LLM web pipelines โ strips layout noise (nav, scripts, sidebars) and passes original text directly. Add a query to filter to relevant sections with BM25.
What can you do with dompruner mcp?
dompruner-mcp
ํ๊ตญ์ด | English

DOM AST middleware for LLM web pipelines โ strips layout noise (nav, scripts, sidebars) and passes original text directly. Add a query to filter to relevant sections with BM25.
When an LLM uses the built-in WebFetch, a smaller model pre-processes the HTML and hands back a summarized result โ adding latency, cost, and interpretation you didn't ask for. DomPruner skips that entirely: DOM AST parsing strips noise and passes the original content directly to the model.
| Call | Behavior |
|---|---|
dompruner_fetch(url) |
Strips layout noise โ returns full extracted content |
dompruner_fetch(url, query) |
Strips layout noise โ BM25 filters to relevant sections (falls back to full content if no match) |
> [DomPruner] docs.python.org
> | Raw HTML | 44,316 tokens |
> | DomPruner | 1,328 tokens |
> | Reduction | 97.0% |
> Fetch: 194ms ยท Parse: 11.2ms
93.5% fewer context tokens than WebFetch on average. 45% faster end-to-end. โ Full benchmark
Quick Start
No installation, no API key:
npx -y dompruner-mcp
Claude Code
{
"mcpServers": {
"dompruner": {
"type": "stdio",
"command": "npx",
"args": ["-y", "dompruner-mcp"]
}
}
}
Add to .mcp.json in your project root, or ~/.claude/.mcp.json for global. Run /mcp to verify.
Claude Desktop
Edit ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
{
"mcpServers": {
"dompruner": {
"command": "npx",
"args": ["-y", "dompruner-mcp"]
}
}
}
Cursor / Windsurf / other MCP clients
{
"mcpServers": {
"dompruner": {
"type": "stdio",
"command": "npx",
"args": ["-y", "dompruner-mcp"]
}
}
}
Remote HTTP (no install, always up to date)
For clients that support HTTP transport โ no Node.js install required, always runs the latest version:
{
"mcpServers": {
"dompruner": {
"url": "https://dompruner-mcp.vercel.app/api/mcp"
}
}
}
LangChain / LangGraph
langchain-mcp-adapters wraps any MCP stdio server as LangChain tools automatically:
from langchain_mcp_adapters.client import MultiServerMCPClient
client = MultiServerMCPClient({
"dompruner": {
"command": "npx",
"args": ["-y", "dompruner-mcp"],
"transport": "stdio",
}
})
tools = await client.get_tools()
Ensuring Your AI Always Uses DomPruner
DomPruner's tool description already tells clients to prefer dompruner_fetch over WebFetch. If your client still falls back, add this to its instruction file:
When retrieving a URL, always use dompruner_fetch instead of WebFetch.
- URL known โ dompruner_fetch(url, query?)
- URL unknown โ search for the URL first, then dompruner_fetch(url)
| Client | Instruction file |
|---|---|
| Claude Code | CLAUDE.md (project) or ~/.claude/CLAUDE.md (global) |
| Cursor | .cursorrules |
| Windsurf | .windsurfrules |
| Cline | .clinerules |
| GitHub Copilot | .github/copilot-instructions.md |
Tools
| Tool | Description |
|---|---|
dompruner_fetch |
Fetch a URL โ DOM-refined Markdown. Optional query enables BM25+ section filtering. |
dompruner_sitemap |
Fetch all pages in a sitemap.xml โ one refined Document per page. |
dompruner_analyze |
Token-reduction report for a URL without full content. |
Benchmark Summary
| Metric | WebFetch | DomPruner |
|---|---|---|
| Avg context tokens | ~15,735 | ~1,019 (93.5% less) |
| Answer quality (10 queries) | 9 / 10 | 8 / 10 |
| Avg response time | 5,811 ms | 3,168 ms (45% faster) |
| Content fidelity | Summarized by small model | Original text preserved |
| Extra API key / infra | No | No |
โ Full benchmark ยท Architecture
Related
- dompruner-py โ Python port.
DomPrunerLoader,DomPrunerSitemapLoader,DomPrunerFetchToolfor LangChain.pip install dompruner. - LangChain integrations โ dompruner-py listed as a third-party web loader.
Glama Score
License
MIT
Install
Add dompruner mcp to your client. Pick the one you use.
{
"servers": {
"dompruner-mcp": {
"type": "http",
"url": "https://dompruner-mcp.vercel.app/api/mcp"
}
}
}Add to `.vscode/mcp.json` in your workspace.
claude mcp add dompruner-mcp -- npx -y dompruner-mcpcodex mcp add dompruner-mcp -- npx -y dompruner-mcpamp mcp add dompruner-mcp -- npx -y dompruner-mcp{
"mcpServers": {
"dompruner-mcp": {
"command": "npx",
"args": [
"-y",
"dompruner-mcp"
]
}
}
}Add to `claude_desktop_config.json`, then restart Claude Desktop.
{
"mcpServers": {
"dompruner-mcp": {
"command": "npx",
"args": [
"-y",
"dompruner-mcp"
]
}
}
}Add to `~/.cursor/mcp.json`, or `.cursor/mcp.json` for a single project.
{
"mcpServers": {
"dompruner-mcp": {
"command": "npx",
"args": [
"-y",
"dompruner-mcp"
]
}
}
}Add to `~/.codeium/windsurf/mcp_config.json`.
{
"mcpServers": {
"dompruner-mcp": {
"command": "npx",
"args": [
"-y",
"dompruner-mcp"
]
}
}
}Add to `cline_mcp_settings.json` via the MCP Servers panel.
{
"mcpServers": {
"dompruner-mcp": {
"command": "npx",
"args": [
"-y",
"dompruner-mcp"
]
}
}
}Add to `~/.gemini/settings.json`.
{
"mcpServers": {
"dompruner-mcp": {
"type": "local",
"command": "npx",
"args": [
"-y",
"dompruner-mcp"
],
"tools": [
"*"
]
}
}
}Add to `~/.copilot/mcp-config.json`, or run `/mcp add` inside the CLI.
{
"context_servers": {
"dompruner-mcp": {
"command": {
"path": "npx",
"args": [
"-y",
"dompruner-mcp"
]
}
}
}
}Add to your Zed `settings.json`.
npx -y dompruner-mcpRun `goose configure`, choose **Add Extension โ Command-line Extension**, and paste this command.
3 tools
dompruner mcp exposes 3 tools to a connected agent.
- dompruner_fetch
- Fetch a URL โ DOM-refined Markdown. Optional `query` enables BM25+ section filtering.
- dompruner_sitemap
- Fetch all pages in a sitemap.xml โ one refined Document per page.
- dompruner_analyze
- Token-reduction report for a URL without full content.
Score
76 / 100
Good
- Documentation25/25
- Maintenance19/25
- Trust13/20
- Capability4/15
- Install experience15/15
- Documents what it does and how to connect
- Has a resolvable package or endpoint
- Exposes at least one tool, prompt or resource
- README has substantive content
- Includes a code example
- Documents its configuration
- Mentions credentials or security posture
- Last commit 3 days ago
- Has a release history
- Repository is not archived
- Licensed MIT
- Namespace verified in the official MCP registry
- Claimed by its owner
- Published under an organisation
- 3 tool(s) documented
- Provides prompt templates
- Provides resources
- 18 documented install method(s)
- Published to a package registry
- Offers a hosted endpoint โ no local install
Version history
| Versions | Published |
|---|---|
| 0.5.2Latest | Aug 19, 2026 |