--- title: "Connect VS Code to WordPress" url: "https://plugpress.co/docs/connect-vs-code-to-wordpress.md" canonical: "https://plugpress.co/docs/connect-vs-code-to-wordpress/" published: "2026-07-28" modified: "2026-08-01" author: "Fahim" description: "Connect VS Code and GitHub Copilot agent mode to WordPress with Saddle. Save one generated mcp.json file and manage your content from Copilot Chat." tags: - "Saddle" --- # Connect VS Code to WordPress **GitHub Copilot’s agent mode can work on your WordPress site from Copilot Chat** — reading and writing posts, pages, and media. Setup is one `.vscode/mcp.json` file that Saddle generates for you. ## What do I need before connecting? - A WordPress site on **HTTPS** with the [Saddle plugin](/docs/what-is-saddle/) installed and activated. - VS Code with GitHub Copilot, and agent mode enabled. ## How do I connect VS Code to my WordPress site? ### Step 1: Open the connect wizard In your WordPress dashboard, go to **Saddle → Connections**, click **Connect an app**, and choose **VS Code**. ![Saddle connect wizard in WordPress showing the Choose app step with Claude, ChatGPT, Claude Code, Cursor, Gemini CLI, VS Code and Any MCP app](https://plugpress.co/wp-content/uploads/2026/07/saddle-connect-wizard-choose-app.png) ### Step 2: Copy the generated config ![Saddle setup step for VS Code showing the .vscode/mcp.json configuration for Copilot agent mode](https://plugpress.co/wp-content/uploads/2026/07/saddle-connect-vs-code-setup.png) Note that VS Code uses `servers`, not `mcpServers`, and needs an explicit type: ``` { "servers": { "saddle-your-site": { "type": "http", "url": "https://your-site.com/wp-json/saddle/v1/mcp", "headers": { "Authorization": "Basic PASTE-YOUR-KEY-HERE" } } } } ``` **Copy it before closing the wizard.** The key appears this once, and backing out early revokes it. Lost it? Use **Rotate key** on the app’s row. ### Step 3: Save it and start the server 1. Save the config as `.vscode/mcp.json` in your project. 2. Open the Command Palette, run **MCP: List Servers**, and start the Saddle server. This file contains a working key — add it to `.gitignore` rather than committing it. ## How do I know it worked? Open Copilot Chat in agent mode and ask: ``` What can you see on my WordPress site? ``` Copilot should report your site name, WordPress version, and content counts, and the app appears in **Saddle → Connections**. ## What can Copilot do on my site? Only what you allow on the [Permissions](/docs/permissions-access-levels/) screen — sites start read-only, and deletions always require a [preview-and-confirm approval](/docs/safe-deletions/). ## It didn’t connect — what now? Check you used `servers` rather than `mcpServers` — copying a config meant for another app is the most common mistake here. Then run **MCP: List Servers** to confirm the server actually started, and use **Test the endpoint** under **Saddle → Connections → Connection details & health** to rule out the site side. More in [Troubleshooting and FAQ](/docs/troubleshooting/), including hosts that strip the `Authorization` header. ## FAQ ### Does this work in normal Copilot chat, or only agent mode? Agent mode. MCP tools are only available to the agent. ### Can I use it across all my projects? The `.vscode/mcp.json` file is per-project. VS Code also supports a user-level MCP configuration if you’d rather set it once. ## Related guides - [Getting started: connect your first AI app](/docs/getting-started/) - [Permissions and access levels](/docs/permissions-access-levels/) - [Editing content and design with AI](/docs/editing-content-and-design/) - [Troubleshooting and FAQ](/docs/troubleshooting/)