/ Verzeichnis / Playground / mcphub.nvim
● Community ravitemer ⚡ Sofort

mcphub.nvim

von ravitemer · ravitemer/mcphub.nvim

Neovim plugin that turns your editor into a first-class MCP client — marketplace installs, Avante/CodeCompanion integration, OAuth PKCE.

ravitemer/mcphub.nvim integrates MCP servers into Neovim workflows. Discover + install via a verified marketplace, chat through Avante/CodeCompanion/CopilotChat, manage OAuth, hot-reload dev servers. Supports stdio, SSE, and Streamable HTTP.

Warum nutzen

Hauptfunktionen

Live-Demo

In der Praxis

mcphub-nvim.replay ▶ bereit
0/0

Installieren

Wählen Sie Ihren Client

~/Library/Application Support/Claude/claude_desktop_config.json  · Windows: %APPDATA%\Claude\claude_desktop_config.json
{
  "mcpServers": {
    "mcphub-nvim": {
      "command": "TODO",
      "args": [
        "See README: https://github.com/ravitemer/mcphub.nvim"
      ],
      "_inferred": true
    }
  }
}

Öffne Claude Desktop → Settings → Developer → Edit Config. Nach dem Speichern neu starten.

~/.cursor/mcp.json · .cursor/mcp.json
{
  "mcpServers": {
    "mcphub-nvim": {
      "command": "TODO",
      "args": [
        "See README: https://github.com/ravitemer/mcphub.nvim"
      ],
      "_inferred": true
    }
  }
}

Cursor nutzt das gleiche mcpServers-Schema wie Claude Desktop. Projektkonfiguration schlägt die globale.

VS Code → Cline → MCP Servers → Edit
{
  "mcpServers": {
    "mcphub-nvim": {
      "command": "TODO",
      "args": [
        "See README: https://github.com/ravitemer/mcphub.nvim"
      ],
      "_inferred": true
    }
  }
}

Klicken Sie auf das MCP-Servers-Symbol in der Cline-Seitenleiste, dann "Edit Configuration".

~/.codeium/windsurf/mcp_config.json
{
  "mcpServers": {
    "mcphub-nvim": {
      "command": "TODO",
      "args": [
        "See README: https://github.com/ravitemer/mcphub.nvim"
      ],
      "_inferred": true
    }
  }
}

Gleiche Struktur wie Claude Desktop. Windsurf neu starten zum Übernehmen.

~/.continue/config.json
{
  "mcpServers": [
    {
      "name": "mcphub-nvim",
      "command": "TODO",
      "args": [
        "See README: https://github.com/ravitemer/mcphub.nvim"
      ]
    }
  ]
}

Continue nutzt ein Array von Serverobjekten statt einer Map.

~/.config/zed/settings.json
{
  "context_servers": {
    "mcphub-nvim": {
      "command": {
        "path": "TODO",
        "args": [
          "See README: https://github.com/ravitemer/mcphub.nvim"
        ]
      }
    }
  }
}

In context_servers hinzufügen. Zed lädt beim Speichern neu.

claude mcp add mcphub-nvim -- TODO 'See README: https://github.com/ravitemer/mcphub.nvim'

Einzeiler. Prüfen mit claude mcp list. Entfernen mit claude mcp remove.

Anwendungsfälle

Praxisnahe Nutzung: mcphub.nvim

How to use MCP servers from Neovim via Avante or CodeCompanion

👤 Neovim devs ⏱ ~20 min intermediate

Wann einsetzen: You live in Neovim and don't want to switch to VS Code for MCP access.

Voraussetzungen
  • Neovim 0.10+ — brew install neovim
  • Avante.nvim or CodeCompanion.nvim installed — Via your plugin manager (lazy.nvim/packer)
  • mcphub.nvim + its Node dependency — See ravitemer.github.io/mcphub.nvim for install snippet
Ablauf
  1. Install via plugin manager
    Add ravitemer/mcphub.nvim to your lazy.nvim config with opts = { ... }.✓ Kopiert
    → :MCPHub opens the management UI
  2. Install a server from the marketplace
    :MCPHub marketplace — search 'github' and install.✓ Kopiert
    → Server starts, tools registered
  3. Use via Avante
    In Avante chat, ask a question — Avante picks up MCP tools.✓ Kopiert
    → Tool calls visible in Avante output

Ergebnis: MCP tools usable inside your editor, no context switch.

Fallstricke
  • Node not on PATH inside Neovim — Use an absolute path in config or ensure Neovim inherits your shell env

How to set up project-local MCP servers that merge with global

👤 Polyglot devs with different tooling per project ⏱ ~15 min intermediate

Wann einsetzen: One project needs postgres MCP, another needs a bespoke internal MCP.

Ablauf
  1. Create .mcphub.json5 at project root
    Define project-specific servers in .mcphub.json5.✓ Kopiert
    → Servers auto-load when you open the project
  2. Verify merge
    :MCPHub status — see which servers are global vs project.✓ Kopiert
    → Merged view

Ergebnis: Context-aware tool loadout per project.

Fallstricke
  • Committing secrets in .mcphub.json5 — Use env var references, gitignore the file if it must contain tokens

How to iterate on a custom MCP server from Neovim

👤 MCP server authors ⏱ ~15 min advanced

Wann einsetzen: You're building a server and want fast iteration.

Ablauf
  1. Enable dev mode
    Add your server with dev=true in mcphub config.✓ Kopiert
    → Hot-reload on file save
  2. Iterate
    Edit server code; mcphub restarts it transparently.✓ Kopiert
    → Updated tools without Neovim restart

Ergebnis: Tight dev loop inside Neovim.

Kombinationen

Mit anderen MCPs für 10-fache Wirkung

mcphub-nvim + github

Use GitHub MCP from Neovim via Avante chat

Install github MCP via marketplace, then ask Avante to show PRs assigned to me.✓ Kopiert

Werkzeuge

Was dieses MCP bereitstellt

WerkzeugEingabenWann aufrufenKosten
(plugin) :MCPHub Commands: status, marketplace, install, logs Manage servers free
(plugin) marketplace-install server_name Quickly add a vetted MCP free
(integration) Avante/CodeCompanion/CopilotChat tools Chat prompts Normal chat usage 1 LLM call + tool calls

Kosten & Limits

Was der Betrieb kostet

API-Kontingent
None (plugin itself)
Tokens pro Aufruf
Adds a tools list to Avante/CC prompts
Kosten in €
Free (MIT)
Tipp
Disable unused marketplace servers — each one adds tools to your prompt budget.

Sicherheit

Rechte, Secrets, Reichweite

Minimale Scopes: Whatever each installed MCP needs
Credential-Speicherung: Env var references in mcphub config
Datenabfluss: Per downstream MCP
Niemals gewähren: Don't commit .mcphub.json5 with inline secrets

Fehlerbehebung

Häufige Fehler und Lösungen

mcphub fails to start Node subprocess

Neovim's PATH may not include Node. Set vim.env.PATH or use absolute path.

Prüfen: :!which node
Avante doesn't see MCP tools

Check Avante adapter version — older versions don't support MCP. Update.

Marketplace shows empty list

Network/firewall blocking marketplace URL. Check :MCPHub logs.

OAuth flow stuck in browser

Copy the URL from :MCPHub logs and paste manually; localhost redirect may not fire from Neovim context.

Alternativen

mcphub.nvim vs. andere

AlternativeWann stattdessenKompromiss
CodeCompanion.nvim (native)You want LLM chat without MCP managementNo marketplace, no OAuth flows
VS Code MCPYou prefer VS CodeNot Neovim

Mehr

Ressourcen

📖 Offizielle README auf GitHub lesen

🐙 Offene Issues ansehen

🔍 Alle 400+ MCP-Server und Skills durchsuchen