Skip to main content
Glama

mcp_searxng

MCP server for privacy-respecting web search via SearXNG.

Requires pi-mcp-bridge to connect to pi.

Prerequisites

  • SearXNG instance running (default: http://localhost:8080/searxng)

Related MCP server: mcp_server_searXNG

Installation

pip install git+https://github.com/timaliev/mcp_searxng.git

Or via uv:

uv tool install git+https://github.com/timaliev/mcp_searxng.git

Configuration

With pi-mcp-bridge

In ~/.pi/agent/settings.json:

{
  "mcpBridge": {
    "servers": [
      {
        "name": "searxng",
        "command": "mcp-searxng",
        "args": [],
        "env": {
          "SEARXNG_URL": "http://localhost:8080/searxng"
        },
        "setupCommands": [
          "uv tool install --python 3.11 git+https://github.com/timaliev/mcp_searxng.git"
        ],
        "githubRepo": "timaliev/mcp_searxng",
        "versionCommand": "mcp-searxng --version"
      }
    ]
  }
}

Standalone MCP client

In ~/.mcp.json:

{
  "mcpServers": {
    "searxng": {
      "command": "mcp-searxng",
      "args": [],
      "env": {
        "SEARXNG_URL": "http://localhost:8080/searxng"
      }
    }
  }
}

Environment Variables

Variable

Default

Description

SEARXNG_URL

http://localhost:8080/searxng

SearXNG instance URL

Tools

Tool

Description

search_web

Web search with engine/category/language filters

search_news

News-only search

search_images

Image search with thumbnails

list_engines

List available/enabled SearXNG engines

Error Handling

All tools return a structured response with a success field. If SearXNG is unreachable or returns an error, success will be false with an error code and detail:

Error Code

Cause

ECONNREFUSED

SearXNG instance is not running or not reachable at the configured SEARXNG_URL

ESEARCH

SearXNG returned an HTTP error (e.g., 500)

EPROCESSING

Unexpected error while processing the request

Example error response:

{
  "success": false,
  "error": "ECONNREFUSED",
  "detail": "Cannot reach SearXNG at http://localhost:8080/searxng"
}

The server does not crash or exit — errors are returned inline so the agent can handle them gracefully.

Development

git clone https://github.com/timaliev/mcp_searxng.git
cd mcp_searxng
uv run mcp-searxng

Available Tools

4 tools
list_enginesA

List all available search engines from the SearXNG instance.

Args: enabled_only: If True (default), return only enabled engines.

Inputs: enabled_only.

search_imagesA

Search images via SearXNG. Returns title, URL, thumbnail, and source.

Inputs: query (required), max_results.

search_newsC

Search news articles via SearXNG.

Inputs: query (required), max_results.

search_webB

Search the web via SearXNG. Optional: filter by engines, categories (general/news/images/science/files/social+media/videos).

Inputs: query (required), engines, language, categories, +1 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.5/5.0

    Scored across 4 tools

    Disambiguation4/5

    search_news and search_images are clearly distinct from search_web, but search_web can also filter by news/images categories, creating some overlap. The dedicated tools return specialized results, so the intent is mostly clear.

    Naming Consistency5/5

    All tools use snake_case with a consistent verb_noun pattern (search_web, search_news, search_images, list_engines). The naming is predictable and uniform.

    Tool Count5/5

    Four tools is well-scoped for a search server: general search, two specialized searches, and a utility for listing engines. Each tool earns its place without bloat.

    Completeness4/5

    Core search and engine listing are covered, but only news and images have dedicated specialized searches. Other categories (videos, science, etc.) are accessible via search_web, so no critical gaps exist, but dedicated support for all categories would be more complete.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      An MCP server that enables web search capabilities by integrating with a SearXNG instance to aggregate results from over 130 engines. It allows users to perform filtered searches across categories like news, science, and social media while supporting advanced parameters for language and time range.
      14
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      A privacy-friendly web search MCP server using SearXNG, enabling searches across multiple engines and categories.
      1
      MIT
    • F
      license
      Not graded
      quality
      D
      maintenance
      Privacy-focused web search MCP server using SearXNG with Streamable HTTP transport, supporting authentication and advanced search parameters.
      -