Pypi Query MCP Server

A Model Context Protocol (MCP) server for querying PyPI package information, dependencies, and compatibility checking.

Local serverstdioPython

What is the Pypi Query MCP server?

If you want an AI assistant working directly with Pypi Query, the pypi query mcp server is the bridge. A Model Context Protocol (MCP) server for querying PyPI package information, dependencies, and compatibility checking.

What Pypi Query does

A Model Context Protocol (MCP) server for querying PyPI package information, dependencies, and compatibility checking.

Key capabilities

  • 📦 Query PyPI package information (name, version, description, dependencies)
  • 🐍 Python version compatibility checking
  • 🔍 Advanced dependency analysis and recursive resolution
  • 📥 Package download with dependency collection
  • 📊 Download statistics and popularity analysis
  • 🏆 Top packages ranking and trends
  • 🎯 MCP prompt templates for guided analysis and decision-making
  • 🏢 Private PyPI repository support

Tools it exposes

Once connected, the assistant can call these 3 tools directly:

  • Cline — The Cline tool exposed by this server
  • Cursor — The Cursor tool exposed by this server
  • Windsurf — Add to your Windsurf MCP configuration (~/.codeium/windsurf/mcp_config.json):

Installing the pypi query mcp server

The server is distributed via PyPI as uvx, so most clients can run it without a manual build step. Add it to your MCP client's configuration and restart the client to pick it up — the copy-paste configs for Claude Desktop, Claude Code and Cursor are on this page.

Configuration

Before the server will start you need to supply 8 environment variables: PYPI_INDEX_URL, PYPI_INDEX_URLS, PYPI_CACHE_TTL, PYPI_LOG_LEVEL, PYPI_PRIVATE_PYPI_URL, PYPI_PRIVATE_PYPI_USERNAME, PYPI_PRIVATE_PYPI_PASSWORD, CACHE_TTL. Keep credentials in your client's env block or a secrets manager rather than committing them.

Where it fits

Developer-tool servers are usually the first ones people connect, because they turn "help me with this code" into an assistant that can actually read the repo and act on it. Pypi Query sits in that group, and the shape of its toolset — Cline, Cursor, Windsurf — tells you what it is really for. Worth comparing against the other developer tools servers in this directory before you commit to one, since several overlap in scope but differ sharply in setup cost and permissions.

Practical notes

  • This server runs locally, so it operates with whatever access your machine and its credentials already have. Scope that deliberately rather than by default.
  • It will not start until its required credentials are present, so set those before wondering why the tools never appear.
  • Maintained by loonghao, written in Python.
  • MCP clients ask for confirmation before each tool call by default. Keep that on while you learn what the pypi query mcp server actually does with your data.
  • Every entry in this directory is reviewed by hand before it goes live, and details are checked against the project's own documentation.

Available tools

ToolWhat it does
ClineThe Cline tool exposed by this server.
CursorThe Cursor tool exposed by this server.
WindsurfAdd to your Windsurf MCP configuration (~/.codeium/windsurf/mcp_config.json):

How to install the Pypi Query MCP server

#### With Private Repository
```json
{
  "mcpServers": {
    "pypi-query": {
      "command": "uvx",
      "args": ["--from", "pypi-query-mcp-server", "pypi-query-mcp"],
      "env": {
        "PYPI_INDEX_URL": "https://pypi.org/pypi",
        "PYPI_PRIVATE_PYPI_URL": "https://private.pypi.company.com",
        "PYPI_PRIVATE_PYPI_USERNAME": "your_username",
        "PYPI_PRIVATE_PYPI_PASSWORD": "your_password",
        "PYPI_CACHE_TTL": "3600"
      }
    }
  }
}

Configuration as documented by the project. Restart the client after saving.

Configuration

VariableDescriptionRequired
PYPI_INDEX_URLEndpoint or connection string the server talks to.Yes
PYPI_INDEX_URLSEndpoint or connection string the server talks to.Yes
PYPI_CACHE_TTLConfiguration value read at startup.Optional
PYPI_LOG_LEVELConfiguration value read at startup.Optional
PYPI_PRIVATE_PYPI_URLEndpoint or connection string the server talks to.Yes
PYPI_PRIVATE_PYPI_USERNAMEConfiguration value read at startup.Optional
PYPI_PRIVATE_PYPI_PASSWORDConfiguration value read at startup.Optional
CACHE_TTLConfiguration value read at startup.Optional

Example prompts to try

  • Use Pypi Query to Cline.
  • Use Pypi Query to Cursor.
  • Use Pypi Query to Windsurf.

Frequently asked questions

It connects Pypi Query to MCP-compatible AI assistants such as Claude and Cursor, exposing 3 tools (Cline, Cursor, Windsurf) that the assistant can call on your behalf. Instead of copying data back and forth by hand, the assistant works with Pypi Query directly.