home / skills / openclaw / skills / local-websearch

local-websearch skill

/skills/stperic/local-websearch

This skill lets you search the web privately via your self-hosted SearXNG, aggregating multiple engines without API keys.

npx playbooks add skill openclaw/skills --skill local-websearch

Review the files below or copy the command above to add this skill to your agents.

Files (3)
SKILL.md
1.6 KB
---
name: searxng
description: Search the web using a self-hosted SearXNG metasearch engine. Aggregates Google, Brave, DuckDuckGo, and more without API keys.
homepage: https://docs.searxng.org
metadata: {"moltbot":{"emoji":"🔍","requires":{"bins":["python3"],"env":["SEARXNG_URL"]}}}
---

# SearXNG Web Search

Privacy-respecting metasearch via your self-hosted SearXNG instance.

## When to use (trigger phrases)

Use this skill when the user asks:
- "search the web for..."
- "look up..." / "find information about..."
- "what is..." (when current info needed)
- "research..." / "search for..."
- "google..." (redirect to privacy-respecting search)

## Quick start

```bash
python3 ~/.clawdbot/skills/searxng/scripts/searxng_search.py "your query"
python3 ~/.clawdbot/skills/searxng/scripts/searxng_search.py "query" --count 10
python3 ~/.clawdbot/skills/searxng/scripts/searxng_search.py "query" --lang de
```

## Setup

Set `SEARXNG_URL` environment variable:
```bash
export SEARXNG_URL="http://your-searxng-host:8888"
```

## Flags

| Flag | Default | Description |
|------|---------|-------------|
| `-n`, `--count` | 5 | Results to return (1-20) |
| `-l`, `--lang` | auto | Language code (en, de, fr, es, etc.) |

## Output

Returns JSON:
```json
{
  "query": "search terms",
  "count": 5,
  "results": [
    {"title": "...", "url": "...", "description": "...", "engines": ["google", "brave"], "score": 1.5}
  ]
}
```

## Notes

- No API keys needed—SearXNG aggregates upstream engines
- Results include source engines for transparency
- Scores indicate relevance (higher = better)
- For news, add "news" to query or use `--lang` for regional results

Overview

This skill lets you search the web using a self-hosted SearXNG metasearch engine to aggregate results from Google, Brave, DuckDuckGo, and other upstream engines without API keys. It returns structured JSON results with titles, URLs, descriptions, contributing engines, and relevance scores. The skill is focused on privacy-respecting, transparent searching from a personal SearXNG instance. It supports language selection and adjustable result counts for flexible queries.

How this skill works

You point the skill to your SearXNG instance via the SEARXNG_URL environment variable and run queries against that endpoint. The skill forwards the query to SearXNG, which aggregates responses from configured upstream engines and returns combined results. The output is a JSON object containing the query, requested count, and an array of results with metadata like engines and relevance scores. Language hints and result limits are passed through to improve relevance and regional coverage.

When to use it

  • When you need current web information or to answer "what is..." queries requiring up-to-date sources
  • When you want privacy-preserving searches without managing API keys
  • When you need to aggregate results from multiple search engines for broader coverage
  • When you want structured JSON output for further processing or automation
  • When you need regional or language-specific results by specifying a language code

Best practices

  • Run the skill against a properly configured and updated SearXNG instance to ensure reliable upstream aggregation
  • Set SEARXNG_URL in your environment to avoid hardcoding endpoints in scripts
  • Limit result count to 1–20 to balance performance and relevance; default is 5
  • Include a language code (e.g., en, de, fr) for regional context on ambiguous queries
  • Add terms like "news" to the query when looking specifically for news articles

Example use cases

  • Quickly gather top web results for a factual question, returning structured results for downstream processing
  • Automate content discovery in a pipeline that ingests titles, URLs, and descriptions from multiple engines
  • Perform regional research by passing a language code to surface local sources
  • Replace direct Google queries with a privacy-focused aggregated search during development
  • Fetch aggregated search results in a script or cron job without relying on external API keys

FAQ

Do I need API keys to use this skill?

No. SearXNG aggregates upstream engines on your behalf, so no API keys are required.

How do I configure where the skill sends queries?

Set the SEARXNG_URL environment variable to your SearXNG instance URL before running queries.

Can I control how many results I get?

Yes. Use the count flag to request 1–20 results; the default is 5.