The YaCy MCP Server acts as a bridge between AI assistants and a private, decentralized web search engine. Instead of relying on traditional, centralized search providers, this tool allows an AI to browse the web or a specific set of documents using YaCy. It is perfect for anyone who wants to give their AI "eyes" on the internet while maintaining complete control over the search results and ensuring a more independent way of finding information. Under the hood, this server implements the Model Context Protocol to provide a specialized `yacy-search` tool. It allows developers to fine-tune how an AI retrieves information by configuring parameters such as the search query, the maximum number of results, and the search scope—whether targeting a local index or the wider global YaCy network. By connecting to a local YaCy instance, typically running on a home server or workstation, the MCP server provides a customizable search API that functions without tracking user behavior or relying on opaque ranking algorithms. For developers building LLM-powered applications, this integration is particularly valuable for creating privacy-focused search agents or internal knowledge retrieval systems. It is designed for easy deployment using environment variables and modern Python tools like `uvx`. By integrating this server into an MCP-compatible client, developers can grant their models the ability to fetch real-time data from a self-hosted or peer-to-peer search index, making it an essential component for projects that prioritize data sovereignty and transparency in information retrieval.
1. Installation To install the YaCy MCP server, you will need the uv package manager. You can install the package for development or run it directly via uvx. Prerequisites:bash pip install uvDevelopment Installation:bash cd yacy-mcp uv sync # Sync all dependencies # OR uv pip install -e .
2. Configuration The server requires a running YaCy instance (typically at http://localhost:8090). You can configure the connection using environment variables. Environment Variables: * YACY_URL: URL of your YaCy instance (Default: http://localhost:8090) Claude Desktop Configuration: Add this to your settings.json (usually located at %APPDATA%\Claude\desktop-config\config.json on Windows or ~/Library/Application Support/Claude/desktop-config/config.json on macOS): json { "mcpServers": { "yacy-mcp": { "command": "uvx", "args": ["yacy_mcp"], "env": { "YACY_URL": "http://localhost:8090" } } } }
3. Available Tools * yacy-search: Search using the YaCy web search engine. * query (string, required): The search query string. * max_results (integer, optional): Maximum number of results to return (default: 10). * resource (string, optional): Search resource (options: local or global, default: global).
4. Example Prompts While no specific natural language prompts are provided in the documentation, you can use the following patterns with an MCP-enabled AI: * "Search YaCy for the latest news on [topic]." * "Find local results for [query] using the YaCy search tool." * "Get the top 5 results from YaCy for [query]."
What you can do with YaCy MCP Server
Use Case 1: Privacy-First Competitive Intelligence Problem: Researchers and business analysts often need to perform deep-dive searches into competitors or sensitive market trends. Using centralized search engines (like Google or Bing) leaves a digital footprint of their queries, which can be tracked, sold to advertisers, or used to profile the user's interests. Solution: By using the YaCy MCP Server, the AI can perform searches through a decentralized, peer-to-peer network. Since YaCy does not store user queries on a central server and respects privacy, the AI can gather market data and summarize findings without exposing the researcher’s intent to big-tech tracking algorithms. Example: A user asks their AI, "Research the recent patent filings and public mentions of [Competitor Name]'s new cooling technology." The AI uses the yacy-search tool to fetch results from the decentralized web, ensuring the query remains private.
Use Case 2: AI-Powered Search for Private Intranets or Local Wikis Problem: Many organizations maintain large internal knowledge bases or "dark web" intranets that are not indexed by public search engines. Employees often struggle to find specific information across these disconnected internal sites using an AI assistant. Solution: YaCy can be configured to crawl and index specific local network resources. By connecting the YaCy MCP Server to a local YaCy instance, a developer can allow an LLM to "search" the company’s private documentation. The AI can then synthesize answers from these internal-only search results. Example: A developer asks, "Find the latest deployment instructions for the legacy server from our internal wiki." The AI calls yacy-search with the resource="local" parameter to pull data indexed from the company's private YaCy node and provides a summary.
Use Case 3: Investigating the "Small Web" and Niche Forums Problem: Commercial search engines prioritize SEO-optimized content and high-authority domains, often burying niche forums, independent blogs, and non-commercial sites. Developers looking for specific community-driven solutions or hobbyist data often find "page one" of Google unhelpful. Solution: YaCy is built on a peer-to-peer architecture where users contribute to the index. This often results in a different "flavor" of search results that includes independent websites that commercial engines might deprioritize. The AI can use this MCP to uncover diverse perspectives or rare technical documentation. Example: A user asks, "Find independent blog posts or community discussions about building a home-scale hydroelectric generator." The AI uses YaCy to bypass standard SEO results and find raw, community-indexed content from the…