websearch-mcp
Integrates with Ollama's OpenAI-compatible endpoints to provide LLM-based synthesis of web content and image description capabilities via vision models.
Supports using OpenAI chat and vision models for processing web search results and generating descriptions for images.
Provides web search capabilities by querying SearXNG instances, allowing for result filtering and content synthesis from search result pages.
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., "@websearch-mcpsearch for the latest news about SpaceX Starship and summarize it"
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.
websearch-mcp
An MCP server that provides web search and page fetching tools for AI agents. Uses SearXNG for search, Crawl4AI for content extraction, and any OpenAI-compatible LLM for server-side synthesis.
Prerequisites
Python 3.12+
SearXNG instance with JSON format enabled (
search.formats: [json]insettings.yml)OpenAI-compatible LLM endpoint (OpenAI, Ollama, vLLM, LiteLLM, etc.)
Installation
# Run directly from GitHub
uvx --from "git+https://github.com/<org>/websearch-mcp" websearch-mcp
# Or clone and install locally
git clone https://github.com/<org>/websearch-mcp
cd websearch-mcp
uv sync
uv run websearch-mcpTools
web_search
Search the web via SearXNG, fetch top result pages, and synthesize with LLM.
Parameter | Type | Required | Description |
| string | Yes | Search query |
| int | No | Max results (default: 10) |
| string[] | No | Only include these domains |
| string[] | No | Exclude these domains |
webfetch
Fetch a single URL, extract content, and process with LLM.
Parameter | Type | Required | Description |
| string | Yes | URL to fetch |
| string | No | Custom instruction for LLM processing |
image-description
Describe an image using a vision language model (VLM). Accepts either base64-encoded image data or an absolute filesystem path to an image file.
Parameter | Type | Required | Description |
| string | Yes | Base64-encoded image data or absolute filesystem path |
Returns a JSON object with description, success status, and optional error message.
Environment Variables
Variable | Required | Default | Description |
| Yes | — | Base URL of SearXNG instance |
| Yes | — | OpenAI-compatible endpoint base URL |
| Yes | — | API key for the LLM endpoint |
| Yes | — | Model name for chat completions |
| No |
| Cache TTL in seconds (0 to disable) |
| No |
| Max cache entries before LRU eviction |
| No |
| Per-page fetch timeout in seconds |
| No |
| LLM request timeout in seconds |
| No |
| Max content size in bytes (5MB) |
| No |
| Default result count for web_search |
VLM Configuration (for image-description tool)
Variable | Required | Default | Description |
| No |
| OpenAI-compatible endpoint for VLM |
| No |
| API key for VLM endpoint |
| No |
| Model name for image description |
| No |
| Max image size in bytes (10MB) |
Agent Configuration
Claude Desktop (stdio)
{
"mcpServers": {
"websearch": {
"command": "uvx",
"args": ["--from", "git+https://github.com/<org>/websearch-mcp", "websearch-mcp"],
"env": {
"SEARXNG_URL": "http://localhost:8888",
"LLM_BASE_URL": "http://localhost:11434/v1",
"LLM_API_KEY": "ollama",
"LLM_MODEL": "llama3"
}
}
}
}Generic MCP Config (stdio)
{
"command": "uvx",
"args": ["--from", "git+https://github.com/<org>/websearch-mcp", "websearch-mcp"],
"env": {
"SEARXNG_URL": "http://localhost:8888",
"LLM_BASE_URL": "https://api.openai.com/v1",
"LLM_API_KEY": "sk-...",
"LLM_MODEL": "gpt-4o-mini"
}
}HTTP Transport
websearch-mcp --transport http --port 3000{
"url": "http://localhost:3000/mcp"
}Development
uv sync
uv run pytest tests/ -vExample Usage
image-description tool
With base64-encoded image:
# Using base64 encoded image data
image_b64 = "iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg=="
result = await image_description(image_b64)
# Returns: {"description": "A small white square", "success": true, "error": null}With filesystem path:
# Using absolute filesystem path
result = await image_description("/path/to/image.png")
# Returns: {"description": "A detailed description of the image", "success": true, "error": null}With Ollama (using llava or other VLM):
{
"mcpServers": {
"websearch": {
"command": "uvx",
"args": ["--from", "git+https://github.com/<org>/websearch-mcp", "websearch-mcp"],
"env": {
"SEARXNG_URL": "http://localhost:8888",
"LLM_BASE_URL": "http://localhost:11434/v1",
"LLM_API_KEY": "ollama",
"LLM_MODEL": "llama3",
"VLM_BASE_URL": "http://localhost:11434/v1",
"VLM_API_KEY": "ollama",
"VLM_MODEL": "llava"
}
}
}
}Available Tools
3 toolsimage_descriptionA
Describe an image using a vision language model.
Args:
image: Either a base64-encoded string containing the image data,
or an absolute filesystem path pointing to an image file.
Returns:
JSON string with description, success status, and error info.
| Name | Required | Description | Default |
|---|---|---|---|
| image | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description carries full burden. Discloses underlying technology (vision language model) and output format structure (JSON with description, success status, error info). Lacks details on image size limits or failure modes.
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?
Uses structured docstring format with Args and Returns sections. Every sentence provides essential information about inputs, outputs, or behavior. No redundant text.
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?
Appropriate for a single-parameter tool. Covers the input parameter fully and summarizes output schema. Could benefit from noting error conditions or image format restrictions, but sufficient for invocation.
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 coverage is 0% (no parameter descriptions in schema). Description fully compensates by specifying acceptable formats: 'base64-encoded string' or 'absolute filesystem path', adding critical semantic meaning beyond the bare 'string' type.
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?
States specific action ('Describe'), resource ('image'), and implementation method ('vision language model'). Clearly distinguishes from web-search siblings by domain (images vs. web content).
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?
No explicit when-to-use versus siblings or alternatives, but usage is implied by the Args section specifying image input requirements (base64 or path). Falls into 'implied usage' category.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
webfetchB
Fetch a single URL, extract content, and process with LLM.
Args:
url: The URL to fetch.
prompt: Optional instruction for LLM processing. If omitted, provides a general summary.
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | ||
| prompt | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description carries full burden. It discloses LLM processing and default summarization behavior when prompt is omitted. However, it lacks critical behavioral details: timeout policies, redirect handling, content size limits, or error responses.
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?
Front-loaded with clear action sentence followed by structured Args section. No redundant text, though the Args format is slightly technical/docstring-like rather than conversational.
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 output schema exists, the description appropriately omits return value details. Parameter documentation is complete, but for a web-fetching tool, the absence of error handling, retry logic, or content type constraints leaves 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 has 0% description coverage (only titles). The Args section compensates by documenting both 'url' and 'prompt', including the optional status and default summary behavior of the prompt parameter. Provides sufficient semantic meaning absent from schema.
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?
States specific actions (fetch, extract, process) and resource (URL). Implicitly distinguishes from sibling 'web_search' (which queries multiple sources) by emphasizing 'single URL' and LLM processing.
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?
Provides no guidance on when to use this tool versus 'web_search' or 'image_description'. No mention of prerequisites like valid URL formats or rate limit considerations.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
web_searchA
Search the web using SearXNG, fetch top result pages, and synthesize with LLM.
Args:
query: The search query string.
max_results: Maximum number of results to return (default: 10).
allowed_domains: Only include results from these domains.
blocked_domains: Exclude results from these domains.
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | ||
| max_results | No | ||
| allowed_domains | No | ||
| blocked_domains | No |
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 the full burden. It successfully discloses the key behavioral trait that results are processed/synthesized by an LLM rather than returned raw. However, it omits rate limits, authentication requirements, error handling behavior, and whether the LLM synthesis incurs additional latency or costs.
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 front-loaded with the core purpose first, followed by an 'Args' section documenting parameters. While the 'Args:' format is slightly informal, every sentence earns its place and the structure is scannable for an LLM agent.
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 has an output schema (not shown), the description appropriately avoids explaining return values. It covers the search engine specificity (SearXNG), the synthesis behavior, and parameter semantics necessary for invocation, though it could benefit from mentioning error scenarios or domain format requirements.
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%, requiring the description to compensate entirely. It documents all 4 parameters (query, max_results, allowed_domains, blocked_domains) with clear semantic meaning. However, it states max_results has a 'default: 10' which contradicts the schema's 'default: null', creating a potentially costly ambiguity for the agent.
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 'Search[es] the web using SearXNG, fetch[es] top result pages, and synthesize[s] with LLM.' This distinguishes it from sibling 'webfetch' (likely raw fetching) by specifying the SearXNG engine and the LLM synthesis step, providing specific verbs and resource scope.
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?
While there is no explicit comparison to siblings, the phrase 'synthesize with LLM' implies usage context—use this when synthesized search results are needed versus raw page fetching. However, it lacks explicit 'when to use vs webfetch' guidance or prerequisites.
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.
3 tool updates
v0.1.0- First observed
image_description - First observed
web_search - First observed
webfetch
TDQS
Each tool has a clearly distinct purpose with no overlap: image_description handles visual analysis, webfetch processes single URLs, and web_search performs multi-result web searches. The boundaries are well-defined, preventing agent misselection.
Two tools follow a consistent 'web_' prefix pattern (web_search, webfetch), but image_description deviates with a different naming convention. The naming is still readable and mostly predictable, with only minor inconsistency.
Three tools is reasonable for a web search server, covering core functionalities (image analysis, URL fetching, web searches). It's slightly thin but well-scoped, with each tool earning its place without bloat.
The toolset covers key web search operations (searching, fetching, image analysis), but there are notable gaps like missing update/delete operations for saved searches or history management. Agents can work around this, but the surface is not fully comprehensive for extended workflows.
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, fetch, extract, and research for AI agents. Markdown output + AI-synthesized answers.
8-tool AI web intelligence suite: search, scrape, screenshot, SEO, docs, crypto, code.
The best web search for your AI Agent
Agent-native search engine with live web research optimized for AI agents.
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/roberthamel/websearch-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server