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

GitHub / Microsoft

Editor

GitHub Copilot in VS Code + xSpeed

GitHub Copilot in VS Code is the AI assistant inside Visual Studio Code, and once xSpeed Hub is added as an MCP server its chat agent can read cache status, purge, change settings and run speed tests on your WordPress sites. You edit one mcp.json entry, approve the sign-in in your browser, and ask from the Chat view.

  • One entry in your user mcp.json covers every site you connected to the Hub
  • Chat: Manage Tool Approval lists the xSpeed tools by server, so you can trust reads and keep writes on a prompt
  • Sits next to the theme or plugin you are editing: check the cache without leaving the editor

Last updated: October 2026

GitHub Copilot in VS Code Editor
xSpeed Hub 29 tools
  • shop
  • blog
  • docs
Connects with mcp.json in your VS Code user profile, or MCP: Add Server. Sign-in: OAuth sign-in or connection token.
01

How do I connect GitHub Copilot in VS Code to xSpeed?

Put your sites in xSpeed Hub once, then add one URL to GitHub Copilot in VS Code.

1Connect4 steps

1Put your sites in xSpeed Hub

Sign in at app.xspeedcache.com with Google or email; the Hub is free and has no site cap. Then connect each WordPress site from its own dashboard: click Connect Hub in the xSpeed Cache top bar, then Connect via xSpeed Hub. Each site needs the free xSpeed Cache plugin.

2Add xSpeed Hub to your user mcp.json

Open the Command Palette and run MCP: Open User Configuration, then add this entry. Servers in your user profile are available in every workspace. MCP: Add Server walks you through the same thing, and the project-level .mcp.json file works too if you want the entry shared with your team; that file uses a top-level mcpServers object instead of servers.

mcp.json (MCP: Open User Configuration)
{
  "servers": {
    "xspeedhub": {
      "type": "http",
      "url": "https://app.xspeedcache.com/xspeed/mcp"
    }
  }
}

3Start the server and sign in

Run MCP: List Servers, pick xspeedhub and choose Start. VS Code asks whether you trust the server, then opens a browser page where you sign in to xSpeed Hub and approve access. There is no token to paste, and VS Code keeps the credentials it receives. Open the Chat view and use the Configure Tools button to see the xSpeed tools.

Text
MCP: List Servers

4Or use a connection token alternative

Copy the connection token from Connect AI in the Hub (only the workspace owner sees it). The input variable makes VS Code ask for the token once and store it, instead of leaving it in the file.

mcp.json (MCP: Open User Configuration)
{
  "inputs": [
    {
      "type": "promptString",
      "id": "xspeed-token",
      "description": "xSpeed Hub connection token",
      "password": true
    }
  ],
  "servers": {
    "xspeedhub": {
      "type": "http",
      "url": "https://app.xspeedcache.com/xspeed/mcp",
      "headers": { "Authorization": "Bearer ${input:xspeed-token}" }
    }
  }
}
1 / 4
Sign-in OAuth sign-in or connection token

VS Code starts the OAuth flow on first connection, beginning with dynamic client registration, and opens a browser page where you approve access in xSpeed Hub. If you prefer a header, add the connection token from the Hub's Connect AI page under headers, using a VS Code input variable so it is not saved in the file.

2Askexample session
Check it worked

Using xSpeed Hub, which of my sites has the lowest cache hit ratio? Only read; do not change anything.

Example session · GitHub Copilot in VS Code

You: I just merged the lazy-load change. Use xSpeed Hub to run a mobile PageSpeed test on shop and compare it with the last stored result.

get_score_history(site: shop) read-only
→ last stored mobile run: score 71, LCP 3.4 s, six days ago

run_speed_test(site: shop, strategy: mobile) uses quota
→ mobile run finished: score 76, LCP 2.9 s

GitHub Copilot in VS Code: Mobile score went from 71 to 76 and LCP from 3.4 s to 2.9 s. That is one run each, and PageSpeed results vary, so run it twice more before you treat the gap as real. The test also spends the shared speed-test allowance.

You: Fine. Leave the cache alone for now.

Using it

02

Prompts to try in GitHub Copilot in VS Code

Paste one as it is, or change the site name.

Prompt
Use xSpeed Hub to list my sites and show page cache status for each one.
Prompt
With xSpeed Hub, purge the shop site cache, then start the preloader and tell me how many URLs it queued.
Prompt
Use xSpeed Hub to run a mobile PageSpeed test on the blog and compare it with the stored score history.
Prompt
Ask xSpeed Hub to preview what optimize_site would change on docs with a safe pass. Do not apply it.
Prompt
Using xSpeed Hub, check that Redis answers on shop before you turn on the object cache.
03

What can GitHub Copilot in VS Code do with xSpeed?

A guide for each job, written for GitHub Copilot in VS Code.

Purge the WordPress cache with GitHub Copilot in VS Code

Clear stale pages after a deploy, an edit or a plugin update, on one site or all of them.

Find out why WordPress pages are not cached with GitHub Copilot in VS Code

Work out why a site misses the cache, serves slow pages or shows a low hit ratio, using read-only checks first.

Scan a website for speed problems with GitHub Copilot in VS Code

Get a graded speed report with the fix for every failing check and a link you can share, for your own site or any public URL.

Run and track PageSpeed tests with GitHub Copilot in VS Code

Read the PageSpeed scores a site already has, run a new test when something changed, and tell a Lighthouse score from a cache benchmark.

Raise a WordPress site's PageSpeed score with GitHub Copilot in VS Code

Preview and apply xSpeed's recommended settings to a site, check the pages still work, and be told plainly what caching cannot fix.

Tune WordPress cache settings with GitHub Copilot in VS Code

See which modules a site has, read their current settings, change them, and turn page caching on or off.

Warm the WordPress cache with GitHub Copilot in VS Code

Fill the page cache before visitors arrive, for example right after a purge or a deploy.

Set up the Redis object cache with GitHub Copilot in VS Code

Connect a site to Redis or Memcached so database results survive between requests.

Manage Cloudflare caching with GitHub Copilot in VS Code

Check the Cloudflare connection, clear the edge cache and switch development mode on or off for a site.

Manage every WordPress site at once with GitHub Copilot in VS Code

Run one action across all of your sites, or a chosen few, and read the result site by site.

Trust and safety

04

Does GitHub Copilot in VS Code ask before it changes my site?

GitHub Copilot in VS Code

In VS Code the default permission level is Manual permissions: a tool call that is not auto-approved shows a confirmation, and you can allow it once or for the session, the workspace or all future calls. Chat: Manage Tool Approval lists tools grouped by MCP server, so you can trust get_cache_status and the other reads while purge_cache and update_settings stay on a prompt. Allow all, Autopilot and global auto-approval skip those prompts, including for external tool calls, and then a write runs as soon as your connection allows writes. xSpeed Hub has no confirmation step of its own.

xSpeed Hub

xSpeed Hub has no confirmation step of its own. Read tools change nothing on your sites, with one exception to know about: contact_support sends an email to xSpeed support, and a read-only connection can still call it. A write tool (a purge, a settings change, a cache toggle, or a speed test that spends the shared allowance) runs as soon as your connection allows writes. Three things stand between a prompt and a change: your connection's scope, because a read-only connection refuses every write tool (the connection token has a Read-only everywhere switch, and a Viewer member only ever gets read access); your AI client's own tool-approval prompt; and the Hub's instructions to the agent, which tell it to confirm the target site and to ask once before a write that touches every site.

Good to know

  • A chat request can enable at most 128 tools. xSpeed Hub adds 29, so if you also run other MCP servers, deselect some in the tools picker when VS Code reports too many.
  • Workspace MCP files such as .mcp.json are committed with the project and inherit Workspace Trust. Put the xSpeed entry in your user configuration unless you want teammates to get it too, and never put a connection token in a shared file.
  • The VS Code documentation lists .vscode/mcp.json as a deprecated destination for new servers. Use the user configuration or a portable .mcp.json.
  • Organizations can manage MCP access through GitHub policies, so a managed account may not be able to add a server at all.

Reference

05

What is GitHub Copilot in VS Code?

GitHub Copilot in VS Code is the AI assistant built into Visual Studio Code. Its chat agent can read your workspace, run commands and call tools, including tools from MCP servers that you add to the editor.

MCP, the Model Context Protocol, is how VS Code reaches services outside your machine. Adding xSpeed Hub as an HTTP server gives the chat agent the Hub's caching tools: status, purge, settings, preloader, object cache, Cloudflare and speed tests, for every site in your workspace.

At a glance

Made by
GitHub / Microsoft
Type
Editor
Connects with
mcp.json in your VS Code user profile, or MCP: Add Server
Sign-in
OAuth sign-in or connection token
Last checked
October 2026
06

Why use GitHub Copilot in VS Code with xSpeed?

Check the cache from the editor

You change a theme or plugin in VS Code, so you can ask the Chat view whether the page cache is on and what the hit ratio is without opening wp-admin.

Approval per tool, per server

Chat: Manage Tool Approval groups tools by MCP server. Trust the reads once, keep each write behind a prompt, and change your mind later in the same list.

One entry for the whole fleet

The Hub fronts every site you connected. One mcp.json entry replaces a server per site, and a single call can return a result for each site.

07

How does GitHub Copilot in VS Code compare with other AI clients?

Every client below reaches the same 29 Hub tools once connected. What differs is where it runs, how you add the server and how it signs in.

ClientMade byTypeHow you connect itSign-in
GitHub Copilot in VS Code GitHub / Microsoft Editor mcp.json in your VS Code user profile, or MCP: Add Server OAuth sign-in or connection token
Cursor Anysphere Editor mcp.json with a url, then OAuth OAuth sign-in or connection token
Windsurf Cognition Editor devin mcp add, then devin mcp login (Cascade: mcp_config.json) OAuth sign-in or connection token
Zed Zed Industries Editor context_servers in settings.json, or Settings, AI, MCP Servers OAuth sign-in or connection token
Kiro Amazon (AWS) Editor an mcp.json entry with a url, then a browser sign-in OAuth sign-in or connection token
08

Which way should I connect?

GitHub Copilot in VS Code can use the Hub, one site's own MCP server, or the no-account Scan MCP. The Hub is the one most people want.

xSpeed Hub MCPMost people

https://app.xspeedcache.com/xspeed/mcp
Best for
Most people. One URL in your AI client, every site behind it.
Reaches
Every site in your workspace, one connection
Sign-in
OAuth sign-in in the browser, or a connection token in an Authorization header
Tools
29 tools (16 read, 13 write), seven of them can act on every site at once
Read the guide →

xSpeed Cache Site MCP

https://your-site.com/xspeed/mcp
Best for
A single site, or work the Hub does not expose, such as database cleanup.
Reaches
One WordPress site
Sign-in
OAuth sign-in by a site admin, or the site's own token in an Authorization header
Tools
The full per-site tool set plus run_command for the WP-CLI surface
Read the guide →

xSpeed Scan MCP

https://xspeedcache.com/scan/mcp
Best for
Grading a site you do not run, or trying xSpeed before you install anything.
Reaches
Any public URL, read-only
Sign-in
None. No account.
Tools
5 tools: run_speed_scan, get_speed_scan and three product-info tools
Read the guide →

WP-CLI

wp xspeed …
Best for
Agents that already run commands on the server, such as Claude Code or Codex over SSH.
Reaches
The site whose server the agent has a shell on
Sign-in
Your server login
Tools
Every xSpeed command: cache, purge, preloader, objcache, cf, score, settings and more
Read the guide →
09

Frequently asked questions

Run MCP: Open User Configuration from the Command Palette and add a server named xspeedhub with type http and the URL https://app.xspeedcache.com/xspeed/mcp. Then run MCP: List Servers, start the server and finish the sign-in in your browser. MCP: Add Server does the same through a guided flow.

No. VS Code signs in to the Hub with OAuth and keeps the credentials it receives. If you would rather use a header, the workspace owner can copy the connection token from the Hub's Connect AI page and you can reference it from the headers field through an input variable.

Not by default. VS Code starts in Manual permissions and shows a confirmation for tool calls that are not auto-approved. The Hub has no confirmation step of its own, so if you trust a write tool, choose Allow all or turn on Autopilot, that write runs without a prompt. Trust reads, keep writes on a prompt. For read-only access, send the connection token with Read-only everywhere on, or sign in as a Viewer member.

The 29 tools of the xSpeed Hub MCP server. Sixteen only read. Thirteen change a site or spend the shared speed-test allowance. Use the Configure Tools button in the chat input to switch individual tools off.

A chat request can enable at most 128 tools across all sources. Open the tools picker and clear some tools or whole MCP servers. xSpeed Hub accounts for 29 of them.

Yes. The xSpeed Cache plugin has its own MCP server at your-site.com/xspeed/mcp, and you add it to mcp.json the same way. The Hub is the better fit once you have more than one site.

Run MCP: List Servers, choose xspeedhub and stop or disable it, and remove the entry from mcp.json to delete it. To clear a saved dynamic sign-in, run Authentication: Remove Dynamic Authentication Providers. Rotating or disconnecting the connection token in the Hub revokes only clients that send that token, so it does not end an OAuth sign-in; that is removed in VS Code.

10

Also works with

Sources checked (5)

Connect GitHub Copilot in VS Code to every site at once.

xSpeed Hub is free and has no site cap. Connect your sites, add one URL, and ask.