Get the FREE Ultimate OpenClaw Setup Guide →

qiskit

Unofficial MCP Server for Qiskit (an open-source SDK for working with quantum computers)

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio barvhaim-qiskit-mcp-server uv run python main.py

How to use

The Qiskit MCP Server exposes a suite of tools that let you define, modify, analyze, and execute quantum circuits using Qiskit, all through the MCP interface. Core tools enable you to create circuits, add gates (including basic and some advanced operations), run circuits on a BasicSimulator, fetch circuit information, and visualize circuits in text or Mermaid formats. Advanced tools extend capabilities to statevector analysis, density matrix computations, circuit optimization with transpiler passes, and creation of variational or QFT circuits. By combining these tools, you can build complex quantum workflows: construct a circuit, apply a sequence of gates, optimize for a target backend, analyze state properties, and render visual representations for understanding before running simulations or experiments.

How to install

Prerequisites:

  • Python 3.8 or newer
  • Git
  • MCP runtime environment (uv) installed per your platform
  1. Clone the MCP server repository (or download the project files): git clone https://github.com/your-org/barvhaim-qiskit-mcp-server.git cd barvhaim-qiskit-mcp-server

  2. Create and activate a Python virtual environment (recommended): python -m venv venv source venv/bin/activate # macOS/Linux .\venv\Scripts\activate # Windows

  3. Install dependencies (Qiskit, MCP framework, NumPy). If a requirements.txt is provided, use that; otherwise install common needs: pip install qiskit fastmcp numpy

  4. Install and configure the MCP runtime (uv) if not already installed. Follow your platform’s guidance to install the MCP runtime. Example (if using uv via pipx/your package manager):

    This step may vary by platform; refer to your MCP runtime docs

    uv sync

  5. Start the MCP server using the defined configuration: uv run python main.py

  6. Verify the server is up by calling a simple tool or checking logs. You should see the MCP server listening for requests and ready to execute the 13 Qiskit tools.

Additional notes

Tips and common considerations:

  • The server exposes 13 tools across core and advanced categories; ensure you provide valid parameters per tool documentation (e.g., circuit_name, num_qubits, gates lists).
  • For visualization tools, ASCII art and Mermaid syntax are returned for easy display in CLI or compatible UIs.
  • If using Claude Desktop or similar integrations, set the mcpServers.qiskit-mcp-server section to point at your local uv run command with the appropriate path to main.py.
  • Ensure Qiskit is configured for the environment where you run the server (backend availability may vary; BasicSimulator is used by default for execution).
  • If you encounter issues with dependencies, creating a virtual environment and explicitly installing qiskit and numpy helps isolate the runtime from system-wide packages.
  • Environment variables: none required by default for basic operation; you can extend the env map in mcp_config if your deployment needs authentication tokens or backend endpoints.

Related MCP Servers

Sponsor this space

Reach thousands of developers