URL Text Fetcher MCP Server
The URL Text Fetcher MCP Server enables web content fetching, link extraction, and web search capabilities using a modern MCP framework.
• Fetch text content: Download all visible text from any specified URL
• Extract page links: Retrieve all href links found on a web page
• Search and fetch web content: Perform web searches using Brave Search and automatically fetch content from top results (up to 10)
• Test Brave Search API: Verify connection and configuration of the Brave Search API
• Get server information: Obtain details about the server's version, implementation, and capabilities
Provides web search functionality using Brave Search API, allowing AI agents to search the web and automatically fetch content from top search results
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@URL Text Fetcher MCP Serversearch for latest AI news and fetch the top 3 articles"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
URL Text Fetcher MCP Server
A modern Model Context Protocol (MCP) server that provides URL text fetching, web scraping, and web search capabilities using the FastMCP framework for use with LM Studio and other MCP-compatible clients.
The server is built using the modern FastMCP framework, which provides:
Clean decorator-based tool definitions
Automatic schema generation from type hints
Simplified server setup and configuration
Better error handling and logging
All security features and functionality have been preserved while modernizing to follow MCP best practices.
Features
This MCP server enables AI models to:
Fetch text content from any URL by extracting all visible text
Extract links from web pages to discover related resources
Search the web using Brave Search and automatically fetch content from top results
Handle errors gracefully with proper timeout and exception handling
Related MCP server: DuckDuckGo MCP Server
Security Features
Enterprise-grade security implementation:
SSRF Protection: Blocks requests to internal networks and metadata endpoints
Input Sanitization: Validates and cleans all URL and query inputs
Memory Protection: Content size limits prevent memory exhaustion
Rate Limiting: Thread-safe API rate limiting with configurable thresholds
Error Handling: Comprehensive exception handling without information leakage
Tools
The server provides three main tools:
fetch_url_text
Description: Downloads all visible text from a URL
Parameters:
url(string, required): The URL to fetch text from
Returns: Clean text content from the webpage
fetch_page_links
Description: Extracts all links from a web page
Parameters:
url(string, required): The URL to fetch links from
Returns: List of all href links found on the page
brave_search_and_fetch
Description: Search the web using Brave Search and automatically fetch content from the top results
Parameters:
query(string, required): The search querymax_results(integer, optional): Maximum number of results to fetch content for (default: 3, max: 10)
Returns: Search results with full text content from each result URL
Prerequisites
Brave Search API Key
To use the search functionality, you'll need a free Brave Search API key:
Visit Brave Search API
Sign up for a free account (2,000 queries/month, max 1 per second)
Get your API key
Copy
.env.exampleto.envand add your API key:cp .env.example .env # Edit .env and set: BRAVE_API_KEY=your_actual_api_key
Installation
Clone this repository
Install dependencies:
uv sync --dev --all-extrasConfigure your environment:
cp .env.example .env # Edit .env file and set your BRAVE_API_KEY
Usage
With LM Studio
Open LM Studio and navigate to the Integrations section
Click "Install" then "Edit mcp.json"
Option A: Use the configuration helper script
./configure_lmstudio.shThis will generate the correct configuration with the right paths for your system.
Option B: Manual configuration - Add the server configuration:
{
"mcpServers": {
"url-text-fetcher": {
"command": "uv",
"args": [
"run",
"url-text-fetcher"
],
"cwd": "/path/to/mcp-server"
}
}
}Note: The API key will be automatically loaded from your .env file in the project directory.
Save the configuration and restart LM Studio
The server will appear in the Integrations section
Standalone Usage
You can also run the server directly:
uv run url-text-fetcherExamples
Once configured with LM Studio, you can ask the AI to:
"Fetch the text content from https://example.com"
"Get all the links from https://news.example.com"
"Search for 'Python web scraping' and show me the content from the top 3 results"
"What's the latest news about AI? Search and get the full articles"
"Find information about MCP servers and fetch the detailed content"
Dependencies
mcp>=1.12.3- Model Context Protocol frameworkrequests>=2.31.0- HTTP library for web requests and Brave Search APIbeautifulsoup4>=4.12.0- HTML parsing and text extraction
Configuration
The server can be configured via the .env file:
# Required: Brave Search API Key
BRAVE_API_KEY=your_api_key_here
# Brave Search API Rate Limit (requests per second)
# Free tier: 1 request per second (default)
# Paid tier: 20 requests per second
# Higher tier: 50 requests per second
# Set this to match your subscription level
BRAVE_RATE_LIMIT_RPS=1
# Optional: Request timeout in seconds (default: 10)
REQUEST_TIMEOUT=10
# Optional: Content length limit in characters (default: 5000)
CONTENT_LENGTH_LIMIT=5000
# Optional: Maximum response size in bytes (default: 10MB)
MAX_RESPONSE_SIZE=10485760Brave Search Subscription Tiers
The server automatically adjusts its rate limiting based on your Brave Search subscription:
Free Tier: 1 request per second (
BRAVE_RATE_LIMIT_RPS=1)Paid Tier: 20 requests per second (
BRAVE_RATE_LIMIT_RPS=20)Higher Tier: 50 requests per second (
BRAVE_RATE_LIMIT_RPS=50)
The server will enforce the configured rate limit across all concurrent requests to ensure you stay within your API quota.
See .env.example for a template.
Development
This project uses:
Python 3.13+
uv for dependency management
MCP SDK for protocol implementation
To set up for development:
Clone the repository
Run
uv sync --dev --all-extrasMake your changes
Test with MCP-compatible clients
Troubleshooting
LM Studio Configuration Issues
If you see errors like "Failed to spawn: url-text-fetcher" in LM Studio logs:
Run the configuration helper:
./configure_lmstudio.shMake sure you're using full paths:
Use the full path to
uv(e.g.,/Users/username/.local/bin/uv)Include the
cwd(current working directory) in your configurationSet the
BRAVE_API_KEYenvironment variable
Test the server manually:
uv run url-text-fetcherThe server should start and wait for input (press Ctrl+C to exit).
Check your API key:
# Check if your .env file has the API key set cat .env | grep BRAVE_API_KEYOr test manually:
export BRAVE_API_KEY=your_actual_api_key echo $BRAVE_API_KEY # Should show your key
Common Issues
"BRAVE_API_KEY environment variable is required": Make sure your
.envfile containsBRAVE_API_KEY=your_actual_api_key"Network error": Check your internet connection and API key validity
"Content truncated": Normal behavior for very long web pages (content is limited to 5000 characters by default)
Error Handling
The server includes robust error handling for:
Network timeouts (10-second default)
Invalid URLs
HTTP errors (4xx, 5xx responses)
Parsing failures
Missing API keys
General exceptions
All errors are returned as descriptive text messages to help users understand what went wrong.
Development
This project uses:
Python 3.13+
uv for dependency management
MCP SDK for protocol implementation
To set up for development:
Clone the repository
Run
uv sync --dev --all-extrasMake your changes
Test with MCP-compatible clients
Debugging
Since MCP servers run over stdio, debugging can be challenging. For the best debugging experience, we strongly recommend using the MCP Inspector.
You can launch the MCP Inspector via npm with this command:
npx @modelcontextprotocol/inspector uv --directory /Users/wallison/TechProjects/mcp-server run url-text-fetcherUpon launching, the Inspector will display a URL that you can access in your browser to begin debugging.
License
MIT License - see LICENSE file for details
Available Tools
5 toolsbrave_search_and_fetchA
Search the web using Brave Search and automatically fetch content from the top results.
Args: query: The search query max_results: Maximum number of results to fetch content for (default: 3, max: 10)
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | ||
| max_results | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. It mentions 'automatically fetch content from the top results,' which hints at behavior, but it lacks details on rate limits, authentication needs, error handling, or what 'fetch content' entails (e.g., full text, summaries). This is a significant gap for a tool with no annotation coverage.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is appropriately sized and front-loaded, with the core purpose in the first sentence and parameter details in a structured 'Args' section. Every sentence adds value without redundancy, making it efficient and easy to parse.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given no annotations, 0% schema description coverage, but an output schema exists, the description is moderately complete. It covers the purpose and parameters but lacks behavioral details like permissions or rate limits. The output schema likely handles return values, so the description doesn't need to explain those, but it should address other contextual gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must compensate. It adds meaning by explaining that 'query' is for search and 'max_results' controls how many top results to fetch content for, including default and max values. This clarifies beyond the basic schema, though it doesn't detail parameter formats or constraints fully.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose with specific verbs ('search the web using Brave Search' and 'fetch content from the top results'), and it distinguishes itself from siblings like 'fetch_page_links' and 'fetch_url_text' by combining search with content fetching in one operation.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for web search and content retrieval, but it does not explicitly state when to use this tool versus alternatives like 'test_brave_search' (which might be for testing) or 'fetch_url_text' (which requires a URL). No exclusions or specific contexts are provided.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
fetch_page_linksB
Return a list of all links on the page.
Args: url: The URL to fetch links from
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool returns a list of links but doesn't cover critical aspects like whether it performs web scraping (implying network calls and potential rate limits), error handling (e.g., for invalid URLs), or output format details. This leaves significant gaps in understanding the tool's behavior.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise and well-structured, with a clear purpose statement followed by parameter details in a labeled 'Args' section. It avoids unnecessary words, though the formatting could be slightly more polished (e.g., bullet points). Every sentence adds value, making it efficient for quick comprehension.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's moderate complexity (web scraping for links), no annotations, and an output schema (which handles return values), the description is minimally adequate. It covers the basic purpose and parameter but lacks details on behavioral traits like network dependencies or error scenarios. The output schema reduces the need for return value explanation, but more context would improve completeness.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description adds meaningful context for the single parameter 'url' by specifying 'The URL to fetch links from,' which clarifies its role beyond the schema's basic title 'Url.' Since schema description coverage is 0%, this compensates well, though it doesn't detail URL format requirements or validation rules. With only one parameter, the baseline is high.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: 'Return a list of all links on the page.' It specifies the verb ('Return') and resource ('list of all links'), making it easy to understand what the tool does. However, it doesn't explicitly differentiate from sibling tools like 'fetch_url_text' (which might fetch text content rather than links), leaving room for minor ambiguity.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools such as 'fetch_url_text' or 'brave_search_and_fetch', nor does it specify prerequisites, exclusions, or contextual cues for selection. This lack of comparative context limits its utility in guiding the agent.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
fetch_url_textA
Download all visible text from a URL.
Args: url: The URL to fetch text from
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries full burden but only states what the tool does, not behavioral traits. It doesn't disclose rate limits, authentication needs, error handling, what 'visible text' means (e.g., excludes scripts/styles), or performance characteristics. The description is minimal beyond the core function.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is extremely concise with zero waste: a clear purpose statement followed by a brief parameter explanation. It's front-loaded with the main function and structured with a labeled 'Args' section, making it easy to parse efficiently.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's low complexity (1 parameter, no annotations but has output schema), the description is reasonably complete for basic use. It covers purpose and parameter semantics adequately. However, it lacks details on behavioral aspects like text extraction scope or error cases, which could be important for an agent's decision-making.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description adds meaningful context for the single parameter 'url' by specifying it's 'The URL to fetch text from,' which clarifies its role beyond the schema's basic type definition. With 0% schema description coverage and only 1 parameter, this adequately compensates, though more detail on URL format expectations could improve it.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the specific action ('Download all visible text') and resource ('from a URL'), distinguishing it from sibling tools like fetch_page_links (which gets links) or brave_search_and_fetch (which includes search). The verb 'download' and scope 'all visible text' provide precise differentiation.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for extracting text content from URLs, but provides no explicit guidance on when to use this tool versus alternatives like fetch_page_links or when not to use it (e.g., for non-text content). The context is clear but lacks sibling differentiation or exclusion criteria.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_server_infoA
Get information about this MCP server including version, implementation, and capabilities.
Returns: Server information including version, implementation type, and available features
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries full burden and does well by specifying what information is returned. It discloses the return format ('Server information including version, implementation type, and available features'), though it doesn't mention potential limitations like rate limits, authentication needs, or error conditions.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is perfectly front-loaded with the core purpose in the first sentence, followed by a clear returns section. Both sentences earn their place by providing essential information without any redundant or unnecessary content.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (0 parameters, no annotations, but has output schema), the description is complete enough. It explains what the tool does and what it returns, and with an output schema present, it doesn't need to detail return value structure. The description covers all essential aspects for this straightforward informational tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has 0 parameters with 100% schema coverage, so the baseline is 4. The description appropriately doesn't discuss parameters since none exist, focusing instead on what the tool returns.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the specific action ('Get information') and resource ('this MCP server'), with explicit details about what information is retrieved ('version, implementation, and capabilities'). It distinguishes itself from sibling tools like search/fetch tools by focusing on server metadata rather than web operations.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for retrieving server metadata, but provides no explicit guidance on when to use this tool versus alternatives. There's no mention of prerequisites, timing considerations, or comparison with other tools that might provide similar information.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
test_brave_searchC
Test the Brave Search API connection and configuration.
Args: query: Test query to search for (default: "test")
| Name | Required | Description | Default |
|---|---|---|---|
| query | No | test |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool tests 'connection and configuration,' implying a read-only diagnostic operation, but does not specify details like authentication requirements, rate limits, error handling, or what the test entails (e.g., whether it performs an actual search or just pings the API). This leaves significant gaps in understanding the tool's behavior.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is appropriately sized and front-loaded, with the main purpose stated clearly in the first sentence. The additional 'Args' section is concise and adds necessary parameter information without redundancy. There is no wasted text, making it efficient, though it could be slightly more structured for better readability.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's low complexity (1 parameter, no annotations, but with an output schema), the description is minimally complete. It covers the basic purpose and parameter, but lacks details on usage context, behavioral traits, and how it differs from siblings. The presence of an output schema means return values are documented elsewhere, so the description need not explain them, but overall it leaves gaps in guiding effective tool selection.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description adds minimal semantics beyond the input schema: it explains that the 'query' parameter is a 'Test query to search for' with a default of 'test'. However, with 0% schema description coverage, the schema only provides basic type and title information. The description compensates slightly by clarifying the parameter's purpose, but it does not elaborate on format, constraints, or how the query is used in the test, resulting in a baseline score.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: 'Test the Brave Search API connection and configuration.' It specifies the action ('Test') and the target ('Brave Search API connection and configuration'), which is clear and specific. However, it does not explicitly differentiate from sibling tools like 'brave_search_and_fetch', which might also involve API interactions, leaving room for ambiguity.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives. It does not mention any prerequisites, exclusions, or comparisons to sibling tools such as 'brave_search_and_fetch' or 'get_server_info', which could be related for testing or configuration purposes. This lack of context makes it unclear when this tool is the appropriate choice.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
5 tool updates
- First observed
brave_search_and_fetch - First observed
fetch_page_links - First observed
fetch_url_text - First observed
get_server_info - First observed
test_brave_search
TDQS
Most tools have distinct purposes: search-and-fetch, fetch links, fetch text, get server info, and test search. However, 'brave_search_and_fetch' and 'test_brave_search' could cause some confusion as both involve Brave Search queries, though their primary functions differ (content fetching vs. API testing).
The naming is mixed with no clear pattern: 'brave_search_and_fetch' uses underscores and compound verbs, 'fetch_page_links' and 'fetch_url_text' follow a verb_noun style, while 'get_server_info' and 'test_brave_search' use different verb styles. This inconsistency makes the set less predictable but still readable.
With 5 tools, this server is well-scoped for its URL text fetching purpose. Each tool earns its place by covering core functionalities like searching, fetching text/links, server info, and API testing, without being overly sparse or bloated.
The toolset covers the main workflows for a URL text fetcher: searching, fetching text and links, and server management. A minor gap is the lack of tools for advanced text processing or filtering, but agents can work around this with the provided fetch operations.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Web search, URL content extraction to Markdown, site mapping, and recursive web crawler.
Fetch pages as markdown, search web and news, extract structured data. For AI agents.
Web search, fetch, extract, and research for AI agents. Markdown output + AI-synthesized answers.
Web search, browser automation, scraping, crawling and CAPTCHA solving for AI agents.
1168
Related MCP Servers
- FlicenseBqualityDmaintenanceEnables fetching visible text content and extracting all links from web pages through URL requests. Designed specifically for LM Studio integration to provide web scraping capabilities.22-
- AlicenseBqualityDmaintenanceEnables web search through DuckDuckGo and webpage content fetching with intelligent text extraction. Features built-in rate limiting and LLM-optimized result formatting for seamless integration with language models.2MIT
- AlicenseNot gradedqualityDmaintenanceEnables web searching through Google, DuckDuckGo, and Bing using a headless Chrome browser, returning structured results with titles, URLs, and snippets. Also supports fetching and extracting text content from any webpage.13MIT
- AlicenseDqualityDmaintenanceEnables AI assistants to reliably fetch web content as markdown and search the web by bypassing bot detection and rendering JavaScript. Provides tools to unblock URLs and search the web with results converted to markdown format.216MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/billallison/brsearch-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server