About FetchV2
FetchV2 is an MCP server for retrieving web pages as clean Markdown, aimed at agents and clients that need to read or research online content. It also supports batch fetching, link discovery, and llms.txt indexes.
Key features
- 01Extract main page content as Markdown
- 02Fetch up to 10 pages per request
- 03Discover and filter page links
- 04Read llms.txt indexes and linked pages
- 05Return raw HTML, tables, and links
- 06Paginate long responses
Use cases
- 01Gather multiple documentation pages in one request
- 02Find guide links on a documentation site
- 03Read llms.txt and retrieve linked documentation
MCP support
FetchV2 exposes web-fetching and link-discovery tools to MCP clients, along with prompts for fetching a URL or researching a topic.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
Tools
4Saved tool list · updated 2w ago
| Parameter | Type | Required | Description |
|---|---|---|---|
| url | string | Yes | The webpage URL to fetch (must be http:// or https://) |
| max_length | integer | No | Maximum characters to return. Use 1000-2000 for summaries, 5000 (default) for full content. |
| start_index | integer | No | Character offset for pagination. Use the value from 'start_index=N' in truncated responses. |
| get_raw_html | boolean | No | Skip extraction and return raw HTML. Use when you need original markup or extraction fails. |
| include_links | boolean | No | Preserve hyperlinks in markdown. Enable to follow references. |
| include_tables | boolean | No | Preserve tables in markdown. Disable for text-only articles. |
| include_metadata | boolean | No | Include title, author, date at top. Disable to save tokens. |
| bypass_robots_txt | boolean | No | Skip robots.txt check. Only for user-initiated requests. |
Details
From the project READMEFetchV2 MCP Server
FetchV2 is a Model Context Protocol (MCP) server that retrieves web pages and returns clean Markdown. It uses Trafilatura to remove navigation, advertisements, footers, and other page elements.
What it does
| Tool | Use |
|---|---|
fetch | Fetch one web page and extract its main content |
fetch_batch | Fetch up to 10 web pages in one request |
discover_links | Find and filter links on a web page |
fetch_llms_txt | Read an llms.txt index and optionally fetch its linked pages |
FetchV2 can return raw HTML, preserve links and tables, and paginate long content.
The fetch tool checks robots.txt by default.
Quick start
Requirements
- Install
uv. - Install Python 3.11 or newer:
uv python install 3.11
Install for Cursor or VS Code
| Cursor | VS Code |
|---|---|
| Install MCP Server | Install on VS Code |
Configure another MCP client
Add this server definition to your MCP client configuration:
{
"mcpServers": {
"fetchv2": {
"command": "uvx",
"args": ["fetchv2-mcp-server@latest"]
}
}
}
Common configuration file locations:
- Claude Desktop on macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Claude Desktop on Windows:
%APPDATA%\Claude\claude_desktop_config.json - Windsurf:
~/.codeium/windsurf/mcp_config.json - Kiro:
.kiro/settings/mcp.jsonin your project
Install in a Python environment
Use one of these commands if you want to install the package directly:
uv add fetchv2-mcp-server
pip install fetchv2-mcp-server
Try it
Ask your MCP client to perform a task such as:
- "Fetch the documentation from
<URL>." - "Find links on
<docs URL>that containtutorial." - "Read these pages and summarize their differences:
[url1, url2, url3]."
Typical documentation workflow
First, find the relevant pages:
discover_links(url="https://docs.example.com/", filter_pattern="/guide/")
Then fetch the selected pages in one request:
fetch_batch(
urls=[
"https://docs.example.com/guide/intro",
"https://docs.example.com/guide/setup",
]
)
Tool reference
fetch
Fetch one web page and extract its main content as Markdown.
fetch(
url: str,
max_length: int = 5000,
start_index: int = 0,
get_raw_html: bool = False,
include_metadata: bool = True,
include_tables: bool = True,
include_links: bool = False,
bypass_robots_txt: bool = False,
) -> str
| Parameter | Type | Default | Description |
|---|---|---|---|
url | str | required | Web page URL |
max_length | int | 5000 | Maximum number of characters to return |
start_index | int | 0 | Character offset for pagination |
get_raw_html | bool | False | Return raw HTML without extraction |
include_metadata | bool | True | Include the title, author, and date |
include_tables | bool | True | Preserve tables in Markdown |
include_links | bool | False | Preserve links in Markdown |
bypass_robots_txt | bool | False | Skip the robots.txt check for a user-requested fetch |
If the response is truncated, use the returned start_index value in the next call.
fetch_batch
Fetch up to 10 web pages and combine the results.
fetch_batch(
urls: list[str],
max_length_per_url: int = 2000,
get_raw_html: bool = False,
) -> str
| Parameter | Type | Default | Description |
|---|---|---|---|
urls | list[str] | required | Web page URLs to fetch |
max_length_per_url | int | 2000 | Maximum number of characters to return for each URL |
get_raw_html | bool | False | Return raw HTML without extraction |
This tool reports a failed URL in its result and continues with the other URLs.
It does not check robots.txt.
discover_links
Find links on a web page and optionally filter them with a regular expression.
discover_links(url: str, filter_pattern: str = "") -> str
| Parameter | Type | Default | Description |
|---|---|---|---|
url | str | required | Web page URL to scan |
filter_pattern | str | "" | Regular expression used to filter links |
The tool resolves relative links and returns up to 100 URLs.
fetch_llms_txt
Read an llms.txt file and list its documentation links.
fetch_llms_txt(
url: str,
include_content: bool = False,
max_length_per_url: int = 2000,
) -> str
| Parameter | Type | Default | Description |
|---|---|---|---|
url | str | required | URL of an llms.txt file |
include_content | bool | False | Fetch the content of all linked pages |
max_length_per_url | int | 2000 | Maximum number of characters to return for each linked page |
By default, this tool fetches only the llms.txt index.
Set include_content=True to fetch all linked pages.
This option can return a large response.
The tool resolves relative URLs, such as /docs/guide.md, against the llms.txt URL.
Prompts
fetch_manualcreates a request to fetch and summarize one URL.research_topiccreates a request to research a topic with optional URLs.
Development
Clone the repository and install the development dependencies:
git clone https://github.com/praveenc/fetchv2-mcp-server.git
cd fetchv2-mcp-server
uv sync --dev
Run the tests:
uv run pytest
Run the server with MCP Inspector:
uv run mcp dev src/fetchv2_mcp_server/server.py
Run lint and type checks:
uv run ruff check .
uv run pyright
Contributing
Read CONTRIBUTING.md before you submit a change.
Support
Use the GitHub issue tracker to report a problem or request a feature.
License
This project uses the MIT License. See LICENSE for details.
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.