mcpField
M
MCP Server for SearXNG n8n Integration

MCP Server for SearXNG n8n Integration

Local
github.com/tamlerSearch4Updated 81w ago

About MCP Server for SearXNG n8n Integration

An MCP server for running SearXNG searches from n8n workflows. Its search tool supports options for categories, engines, language, time range, safe-search level, and output format.

Key features

  1. 01Search through SearXNG
  2. 02Set categories, engines, and language
  3. 03Choose time range and safe-search level
  4. 04Select JSON, CSV, RSS, or HTML output

Use cases

  1. 01Run web searches in n8n workflows
  2. 02Filter results by language and time range
  3. 03Choose a specific search output format

MCP support

The MCP server exposes a SearXNG search tool to n8n's MCP node. A query is required, with additional options for filtering and output.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

mcp.json · Universal config
{
"mcpServers": {
"searxng-n8n": {
"command": "npx",
"args": [
"-y",
"mcp-server-searxng-n8n"
]
}
}
}
Run commandnpx -y mcp-server-searxng-n8n

Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.

Packages
npmmcp-server-searxng-n8n

Tools

1

Saved tool list · updated 3w ago

ParameterTypeRequiredDescription
qstringYesThe search query string (REQUIRED). Example: "n8n automation"
categoriesstringNoOptional: Comma separated list of search categories (e.g., "general,images")
enginesstringNoOptional: Comma separated list of search engines to use (e.g., "google,brave")
languagestringNoOptional: Language code for the search (e.g., "en", "de")
time_rangeenumNoOptional: Time range for search resultsday | month | year
safesearchenumNoOptional: Safe search level (0: None, 1: Moderate, 2: Strict)0 | 1 | 2
image_proxybooleanNoOptional: Proxy image results through SearxNG (true/false)
enabled_pluginsstringNoOptional: Comma-separated list of enabled plugins
disabled_pluginsstringNoOptional: Comma-separated list of disabled plugins
enabled_enginesstringNoOptional: Comma-separated list of enabled engines (overrides general engines list)
disabled_enginesstringNoOptional: Comma-separated list of disabled engines
formatenumNoOptional: Output format for results. Defaults to "json".json | csv | rss | html

Details

From the project README

MCP Server for SearXNG n8n Integration

A Model Context Protocol (MCP) server specifically designed for using SearXNG with n8n workflows.

Usage in n8n

  1. Prerequisites:

    • A running n8n instance.
    • Access to a SearXNG instance (e.g., https://your-searxng-instance.com).
    • The n8n-nodes-mcp package installed in your n8n instance.
  2. Configure MCP Node (Server Connection):

    • Add an "MCP" node to your workflow.
    • In the node settings, under the Server Connection section:
      • Command: npx
      • Arguments (for npx): -y mcp-server-searxng-n8n --instance=https://your-searxng-instance.com
        • Replace https://your-searxng-instance.com with your actual SearXNG URL.
      • Environment Variables: (Leave empty)
  3. Configure MCP Node (Tool Operation):

    • Still in the MCP node settings, under the Operation section:
      • Tool Name: Select search from the dropdown.
      • Arguments (for the 'search' tool): Enter a JSON object containing the parameters for your search. See examples below. You can use n8n expressions like {{ $json.chatInput }} as values within the JSON.

Available Search Parameters (for Tool Arguments JSON)

The search tool supports the following parameters within the JSON object (only q is required):

  • q (required): The search query string
  • categories: Comma-separated list of search categories
  • engines: Comma-separated list of search engines to use
  • language: Language code for the search
  • time_range: Time range for results (day, month, year)
  • safesearch: Safe search level (0: None, 1: Moderate, 2: Strict)
  • image_proxy: Proxy image results through SearXNG
  • enabled_plugins: Comma-separated list of enabled plugins
  • disabled_plugins: Comma-separated list of disabled plugins
  • enabled_engines: Comma-separated list of enabled engines
  • disabled_engines: Comma-separated list of disabled engines
  • format: Output format (json, csv, rss, html). Defaults to json.

Example n8n Tool Arguments (JSON)

JSON Output (Default):

{
  "q": "n8n automation",
  "engines": "google,duckduckgo",
  "language": "en"
}

HTML Output:

{
  "q": "n8n automation",
  "format": "html"
}

(Remember to only include the parameters you need in the JSON)

Development

git clone https://github.com/tamler/mcp-server-searxng-n8n.git
cd mcp-server-searxng-n8n
npm install
npm run build

Test with:

# Note the double dash -- to pass arguments to the script via npm start
npm start -- --instance=https://your-searxng-instance.com

License

MIT

Comments

Markdown supported

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.