Get the FREE Ultimate OpenClaw Setup Guide →

plex

An implementation of MCP for the Plex API

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio vyb1ng-plex-mcp npx plex-mcp \
  --env PLEX_URL="http://your-plex-server:32400"

How to use

This MCP server lets you search, browse, and manage your Plex libraries using Claude. It exposes functionality for media search across movies, TV shows, and music, as well as library navigation, recently added content, and watch history. Beyond basic browsing, you can leverage the Music Discovery tools to get natural language-based recommendations and smart search prompts, create and manage Playlists, and retrieve detailed Media Info such as codecs, bitrates, and file sizes. The server also offers data access via structured URIs (e.g., plex://libraries, plex://recent) and provides prompts like playlist_description, content_recommendation, smart_playlist_rules, media_analysis, and server_troubleshooting to assist with curation and diagnostics. These capabilities are exposed through Claude’s MCP interface when configured with the Plex MCP server.

To use it, set up the Plex MCP in Claude (or your Claude Desktop MCP settings) with the provided environment variable for PLEX_URL. You can authenticate via OAuth or use a static PLEX_TOKEN as described in the setup notes. Once running, invoke search queries (e.g., searching for a movie or artist), browse libraries, and use the music discovery prompts to get personalized suggestions. For automated workflows, use the JSON-structured data endpoints to programmatically access library data and watch history.

How to install

Prerequisites:

  • Node.js (>= 14) and npm or pnpm
  • Access to the internet to fetch the Plex MCP package

Option A: Install via Smithery (recommended)

  • Run:
npx -y @smithery/cli install @vyb1ng/plex-mcp --client claude
  • This installs and configures the Plex MCP server for Claude access.

Option B: Manual setup (CLI / local development)

  • Ensure Node.js is installed.
  • Install the Plex MCP package globally or run via npx when starting:
npx plex-mcp
  • Configure Claude Desktop with the following mcpServers entry (example):
{
  "mcpServers": {
    "plex": {
      "command": "npx",
      "args": ["plex-mcp"],
      "env": {
        "PLEX_URL": "http://your-plex-server:32400"
      }
    }
  }
}

Notes:

  • Replace http://your-plex-server:32400 with your actual Plex server address.
  • If you use OAuth, you’ll use the authenticate_plex tool within Claude to obtain a login URL.
  • If you opt for a static token, set PLEX_TOKEN in the env as described in the Authentication section.

Additional notes

Tips and caveats:

  • Ensure PLEX_URL is reachable from the environment where the MCP server runs; firewalls or network rules may block access.
  • If you need verbose troubleshooting, enable MCP_HTTP_DEBUG in the env; logs will include request/response details with sensitive headers redacted.
  • Smart playlists are currently disabled due to broken filter logic; you can still create and manage standard playlists and access playlist contents.
  • The server exposes URI-based data access (plex://libraries, plex://recent, plex://playlists) for automation; leverage these for integration in scripts or dashboards.
  • If you encounter authentication issues, verify that the Plex token (if using static token) has the necessary scope and that your Plex server is accessible publicly or within your VPN/network.

Related MCP Servers

Sponsor this space

Reach thousands of developers