xSpeed Cache is officially live! Get 50% OFF during Launch Week — Lifetime starts at just $79Lifetime from $79 — 50% OFF, Launch Week! See Plans →

See Plans →
Features
xSpeed Hub Pricing Docs Blog Scan
Appearance
Get Plugin

Connect Claude Code to xSpeed Hub MCP

AI & MCP 3 min read Updated Oct 2026

Add xSpeed Hub to Claude Code with one command, sign in with /mcp, and manage every WordPress site you connected to the Hub from the terminal.

You add one remote MCP server, xspeedhub, to Claude Code. It points at xSpeed Hub, so Claude Code reaches every site in your Hub workspace through it.

Before you start

You need a free xSpeed Hub account with at least one site connected. Connect your sites to xSpeed Hub first if you have not.

Steps

  1. Add xSpeed Hub to Claude Code

    Run this once. --scope user makes the server available in every project; leave it off and it applies to the current project only, which is Claude Code's default.

    Terminal
    claude mcp add --transport http --scope user xspeedhub https://app.xspeedcache.com/xspeed/mcp
  2. Sign in with /mcp

    Start Claude Code, run /mcp, pick xspeedhub and finish the sign-in in your browser. You approve access on an xSpeed Hub page; there is no token to paste, and Claude Code keeps the credentials it receives and refreshes them.

    Text
    /mcp

Sign-in

OAuth sign-in or connection token. Run /mcp and approve access in the browser; Claude Code stores the tokens and refreshes them. If you would rather not use a browser, add the connection token from the Hub's Connect AI page with --header instead.

Alternative

Or use a connection token

If you prefer a header to a browser sign-in, copy the connection token from Connect AI in the Hub (only the workspace owner sees it) and pass it with --header. A rejected header shows as a failed connection rather than falling back to sign-in.

Terminal
claude mcp add --transport http --scope user xspeedhub https://app.xspeedcache.com/xspeed/mcp \
  --header "Authorization: Bearer <your connection token>"

Check it worked

Ask Claude Code this. It only reads, so nothing changes on your sites.

Prompt
Use xSpeed Hub to list my sites and tell me which ones have page caching turned off.

A first prompt

Prompt
Use xSpeed Hub to show the cache hit ratio for every site and flag anything under 70%.

If something does not work

  • Without --scope user the server is added to the current project only, so it will look missing when you start Claude Code in another folder.
  • If you add the same server name in two scopes with different URLs, Claude Code warns about the conflict and stores a separate sign-in per URL. Keep one entry.
  • In claude -p and other non-interactive runs there is no /mcp panel, so sign in first with /mcp in an interactive session or with claude mcp login xspeedhub.