Skip to main content

DDGS MCP Server

A Model Context Protocol (MCP) server that provides DuckDuckGo Search capabilities to AI agents.

Features

  • search_text: Advanced metasearch using bing, brave, duckduckgo, google, mojeek, yahoo, yandex, wikipedia.
    • Full Content Extraction: Optionally fetch complete page content (not just snippets) for comprehensive context.
  • search_news: Find latest updates, releases, and tech news.

Full Content Extraction

For coding agents that need complete context from search results, enable full page content fetching:

Usage

{
  "query": "python async programming tutorial",
  "fetch_full_content": true,
  "max_content_length": 50000,
  "max_results": 5
}

Parameters

Parameter Type Default Description
fetch_full_content boolean false Enable full page content extraction
max_content_length integer 50000 Maximum characters per page (when fetch_full_content is true)

Response Structure

When fetch_full_content is enabled, each result includes a full_content field:

[
  {
    "title": "Python Async Programming Guide",
    "href": "https://example.com/python-async",
    "body": "Brief snippet from search results...",
    "full_content": "Complete extracted article text with all paragraphs, code examples, and detailed explanations..."
  }
]

Performance Notes

  • Content extraction adds ~1-3 seconds latency per page
  • Up to 5 pages are fetched concurrently to minimize total time
  • Failed fetches return [Content extraction failed or blocked] without breaking the search
  • Uses Trafilatura for high-quality text extraction

Installation & Usage

You can run this server directly using uvx without installing it globally.

VS Code (Claude Desktop / Cline)

Add this to your MCP settings file (e.g., cline_mcp_settings.json or claude_desktop_config.json):

{
  "mcpServers": {
    "ddgs-search": {
      "command": "uvx",
      "args": [
        "ddgs-mcp-server"
      ],
      "disabled": false,
      "alwaysAllow": []
    }
  }
}

Manual Execution

uvx ddgs-mcp-server

Secrets & Configuration

This project technically does not require API keys to run locally, as it scrapes DuckDuckGo. However, for publishing or proxy usage, you should configure your environment.

1. Set up Secrets

Copy the example file:

cp .env.example .env

2. Required Tokens

Token Purpose How to Get It
PyPI API Token Publishing to PyPI 1. Go to PyPI Account Settings
2. Select "Add API Token"
3. Scope to "Entire account" (for first publish)
4. Set as TWINE_PASSWORD in .env
Proxy URL Bypassing Blocks (Optional) Use any HTTP/SOCKS5 proxy provider if you encounter rate limits.

Development / Publishing

To build and publish this package to PyPI (using the secrets from above):

  1. Build:

    pip install build twine
    python -m build
    
  2. Publish (loads secrets from .env if you export them, or prompts you):

    # If using .env variables (PowerShell)
    # $env:TWINE_USERNAME = "__token__"
    # $env:TWINE_PASSWORD = "pypi-..."
    
    python -m twine upload dist/*
    

Metadata

Release files for ddgs-mcp-server 0.5.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ddgs-mcp-server 0.5.1
File Size Uploaded Provenance
ddgs_mcp_server-0.5.1.tar.gz 9.4 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for ddgs-mcp-server 0.5.1
File Interpreter ABI Platform
ddgs_mcp_server-0.5.1-py3-none-any.whl Python 3 none any Details

Total release size: 16.4 kB

Release files / ddgs_mcp_server-0.5.1.tar.gz

Download URL ddgs_mcp_server-0.5.1.tar.gz
Size 9.4 kB
Tags Source
SHA-256 checksum
How to use checksums
8b0281c60f1a622587c5a6215491b543a3915963c50082f5fdf5e13cb3ddb704
BLAKE2b-256 checksum
How to use checksums
5ca04e552ec9d61964b87bd2eae5cde6ea5baa49836033c8a4186b1bca64d469
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.7

Release files / ddgs_mcp_server-0.5.1-py3-none-any.whl

Download URL ddgs_mcp_server-0.5.1-py3-none-any.whl
Size 6.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b6b8b614472dfa2a706ac4e8970bd64275e775b7bd7e61a6a91f387666212c8d
BLAKE2b-256 checksum
How to use checksums
c49af645d8ac41c29760165f751e95c0be243008e17ec1aeed43d76d99384900
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.7

Security for ddgs-mcp-server 0.5.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page