---
title: "How to Connect Cursor to WordPress via MCP"
url: "https://wpimportexport.com/connect-cursor-to-wordpress-mcp/"
description: "Connect Cursor to your WordPress site with the official MCP Adapter and an Application Password, then audit, export and import content from a Cursor chat."
type: post
published: 2026-11-05T13:23:51+00:00
modified: 2026-11-14T10:33:14+00:00
categories: ["AI", "Tutorials"]
tags: ["Abilities API", "AI Agents", "Cursor", "Import Export by RockStarLab", "WordPress automation", "WordPress Import Export Plugin"]
docs_topics: ["Using with AI agents"]
---

# How to Connect Cursor to WordPress via MCP

Cursor talks to MCP (Model Context Protocol) servers directly over HTTP, so a WordPress site needs no bridge or local proxy to show up in a Cursor chat, only an entry in Cursor’s MCP settings. From the chat you can then count and list content, export pages and posts, check import jobs or sync content between sites. On the WordPress side, the official [MCP Adapter](https://wordpress.org/plugins/mcp-adapter/) plugin is the server.

The free [Import Export by RockStarLab](https://wordpress.org/plugins/import-export-by-rockstarlab/) plugin writes the Cursor settings for you and adds more than 100 actions for exports, imports and content sync. It was tested with Cursor 3.28, WordPress 7.1, MCP Adapter 0.7.1 and version 2.1.18 of the plugin.

## Short Answer

1. Go to **Import Export by RockStarLab > Plugin Options > AI Agent Connection**, turn on **Enable Abilities API** and let the wizard activate MCP Adapter.
2. Create an Application Password in **Users > Profile**.
3. In step 4 of the wizard, choose **Cursor**, paste the password, generate the command and run it in your terminal. It adds a `wordpress` server to `~/.cursor/mcp.json`.
4. In Cursor, open **Customize > MCPs** and check that **wordpress** is **Connected** with 3 tools.
5. Start a new chat and send the first request from the wizard.

## What You Need

- **WordPress 6.9 or newer**, where the Abilities API is part of core, and an administrator account.
- **HTTPS on a live site.** WordPress only offers Application Passwords over HTTPS, except on local development sites.
- **Cursor**, signed in. MCP tools use your normal Cursor plan and model requests.
- **Python 3** if you use the one-command setup. It is preinstalled on most Macs and Linux systems. Without Python, use the **Custom config** method below.

## Step 1: Turn On Agent Access

Go to **Import Export by RockStarLab > Plugin Options > AI Agent Connection** and turn on **Enable Abilities API**. The setup wizard appears below the switch.

![Import Export by RockStarLab AI Agent Connection settings with the Enable Abilities API switch turned on and Claude Code among the supported agents](https://wpimportexport.com/wp-content/uploads/2026/11/01-enable-abilities-api.webp)

_Turn on Enable Abilities API in Plugin Options > AI Agent Connection._

## Step 2: Activate MCP Adapter and Create a Password

Step 2 of the wizard installs and activates MCP Adapter with one click. Step 3 links to your profile, where you create an Application Password: enter a name such as “Cursor”, click **Add Application Password** and copy the password. WordPress shows it only once.

![Connect your AI agent wizard: site check ready with 105 plugin actions, MCP Adapter 0.7.1 ready, and the step to create an Application Password](https://wpimportexport.com/wp-content/uploads/2026/11/02-wizard-steps.webp)

_The wizard checks the site and MCP Adapter before you create a password._

## Step 3: Add the Site to Cursor

In step 4 of the wizard, choose **Cursor** as the AI app and **One command** as the method, select your terminal, and paste your username and the Application Password. Click **Generate connection** and **Copy result**. The command is built in your browser; the password is not sent anywhere.

![Wizard step 4 with Cursor and One command selected and the generated python3 command that adds WordPress to the Cursor mcp.json](https://wpimportexport.com/wp-content/uploads/2026/11/03-cursor-command.webp)

_For Cursor, the wizard builds a short Python command that adds the site to ~/.cursor/mcp.json._

The command is a short Python script. Close Cursor, paste the command into a terminal and run it. It reads `~/.cursor/mcp.json` (on Windows `%USERPROFILE%\.cursor\mcp.json`), adds a `wordpress` server, keeps every other server in the file and prints `WordPress added. Restart your AI app.` If a server named `wordpress` already exists, it stops and changes nothing.

With **Custom config**, the wizard shows the same settings as JSON instead:

```
{
  "mcpServers": {
    "wordpress": {
      "url": "https://your-site.com/wp-json/mcp/mcp-adapter-default-server",
      "headers": {
        "Authorization": "Basic ..."
      }
    }
  }
}
```

Paste it into `~/.cursor/mcp.json`. If the file already has servers, add only the `wordpress` entry inside the existing `mcpServers` object. The `Basic` value is your username and Application Password in Base64, which is an encoding, not encryption, so keep the file private.

## Step 4: Check the Connection

Open Cursor and go to **Customize > MCPs**. The **wordpress** server should be listed under **Connected** with **3 tools enabled**.

![Cursor Customize MCPs list with the wordpress server connected and 3 tools enabled](https://wpimportexport.com/wp-content/uploads/2026/11/04-cursor-mcp-connected.webp)

_In Customize > MCPs, the wordpress server is connected with 3 tools._

The three tools are _Discover Abilities_, _Get Ability Info_ and _Execute Ability_. They are the same on every site with MCP Adapter. The actual actions (“abilities”) come from plugins: Import Export by RockStarLab adds its export, import, job, sync and migration actions, and other plugins add their own.

Cursor connected on the first try in our test. It sends every header the current MCP protocol asks for, so no extra settings were needed.

## Step 5: Send the First Request

Start a new chat and paste the first request from the wizard. It only reads information:

```
Connect to my WordPress MCP server. Discover its abilities, get the input schema for rsl-ie/get-capabilities, then execute it with empty parameters {}. Summarize what Import Export by RockStarLab can do. Do not modify any content or settings.
```

Cursor listed the abilities, read the input of `rsl-ie/get-capabilities` and ran it: three calls to the WordPress tools in 29 seconds. It also searched the saved tool output on the computer to read the full list of abilities, which is how Cursor handles large results.

![Cursor chat listing WordPress abilities, getting the input schema and running the read-only capabilities lookup](https://wpimportexport.com/wp-content/uploads/2026/11/05-cursor-tool-calls.webp)

_Cursor calls the three WordPress MCP tools: 29 seconds for the first request._

The answer named the plugin version, said that the Pro add-on is not active and summarized the plugin’s actions by area:

![Cursor answer showing Import Export by RockStarLab version 2.1.18, Pro add-on not active and a summary of the plugin's abilities](https://wpimportexport.com/wp-content/uploads/2026/11/06-cursor-first-answer.webp)

_The first, read-only request: plugin version, Pro status and a summary of the plugin's actions._

## A Real Task: Stale Pages and a CSV Inventory

The second request asked for published pages that nobody has edited since 2024, and for a CSV inventory of all published pages:

```
Check my WordPress site for stale content. Find published pages that have not been modified since January 1, 2024. For each one, show the title, address, last modified date and word count. Then export all published pages to a CSV file named content-inventory with ID, Title, Permalink, Status, Modified Date, Word Count and the Yoast meta description, and give me the browser download link. Do not change any content.
```

Without any hints, Cursor used the plugin’s own export. The job log on the site shows a new export job named `content-inventory.csv` with exactly the requested fields (`ID`, `post_title`, `permalink`, `post_status`, `post_modified`, `word_count`, `_yoast_wpseo_metadesc`), limited to published pages, and all 9 rows were written. Our Cursor account then reached its usage limit before Cursor wrote its summary, so there is no screenshot of the final answer. Once the job is finished, the file is also available under **Import Export by RockStarLab > Jobs Log**.

The same inventory can be built by hand in the dashboard, as described in [WordPress Content Inventory: Export All Pages with Dates, Authors and Status](https://wpimportexport.com/wordpress-content-inventory-export/).

## More Requests to Try

- “How many posts, pages, comments and media files does the site have? Do not change anything.”
- “List the last 10 import and export jobs with their status, and show the errors of any job that failed.”
- “Export all blog posts published in 2025 to an Excel file with the title, permalink, categories and featured image URL, and give me the browser download link.”
- “Find pages whose content contains old-domain.com and list their titles and addresses.”

Keep the requests specific. When you need a particular action, name it (“use rsl-ie/export-start”), and ask for the **browser download link**, which opens for any logged-in administrator.

## Before You Let It Change Anything

Reading and exporting do not change the site. Imports, syncs and setting changes do. Make a backup first: with UpdraftPlus, click **Backup Now**, or turn on **Enable Abilities API for UpdraftPlus** on the same settings page and ask Cursor to run `rsl-ie/updraftplus-backup-start` and check it with `rsl-ie/updraftplus-backup-status`. Both ways are described in [How to Create a WordPress Website Backup and Restore It](https://wpimportexport.com/how-to-create-a-wordpress-website-backup-and-restore-it/).

Depending on your settings, Cursor either asks before it runs a tool or runs it automatically. Every action goes through the same _Execute Ability_ tool, so when auto-run is on, Cursor can also run actions that change content. Try new kinds of tasks on a staging site first, and check which ability Cursor plans to run before a task that writes.

## Troubleshooting

All connection errors with their exact messages and fixes are collected in [WordPress MCP Adapter Errors: Fix 401, 404 and Application Password Problems](https://wpimportexport.com/wordpress-mcp-adapter-errors/).

### The server shows an error or “0 tools”

Check the address in `mcp.json`: it must end with `/wp-json/mcp/mcp-adapter-default-server`. Open `https://your-site.com/wp-json/` in a browser to make sure the REST API answers, and check in the wizard that steps 1 and 2 show **Ready**.

### HTTP 401

The username or Application Password is wrong, or the server drops the `Authorization` header. Create a new Application Password and generate the settings again. On Apache, add `SetEnvIf Authorization "(.*)" HTTP_AUTHORIZATION=$1` to `.htaccess` if the header does not reach WordPress.

### “WordPress already exists. Use Custom config.”

The one-command setup never overwrites an existing `wordpress` entry. Edit `~/.cursor/mcp.json` and replace that entry with the **Custom config** settings, or remove it and run the command again.

### “Invalid config. Use Custom config.”

Your `mcp.json` is not plain JSON, for example because it contains comments or trailing commas. Add the `wordpress` entry by hand.

### Cursor connects but finds no rsl-ie abilities

**Enable Abilities API** is off, or the account has no administrator rights. Turn the switch on and use an administrator’s Application Password.

## FAQ

### Does this work with other MCP clients?

Yes. The same wizard generates settings for Claude Code, GitHub Copilot in VS Code, Codex and Gemini CLI. See [How to Connect Claude Code to WordPress via MCP](https://wpimportexport.com/connect-claude-code-to-wordpress-mcp/) and [How to Connect GitHub Copilot to WordPress via MCP](https://wpimportexport.com/connect-github-copilot-to-wordpress-mcp/), or [How to Connect OpenAI Codex to WordPress via MCP](https://wpimportexport.com/connect-codex-to-wordpress-mcp/).

### Can I connect several sites?

Yes. Add one entry per site in `mcpServers`, for example `wordpress-shop` and `wordpress-blog`, each with its own address and Application Password, and say in your request which one to use.

### Do I need the Pro version?

No. The connection and the free actions for posts, pages, comments, media, URL lists, jobs, content sync and migration work with the free plugin. The Pro add-on adds actions for WooCommerce, custom post types, users and menus.

## Related Guides

- [Letting an AI Agent Edit WordPress Content Safely: Permissions, Staging, Rollback](https://wpimportexport.com/ai-agent-edit-wordpress-content-safely/)
- [WordPress MCP Adapter errors: fix 401, 404 and Application Password problems](https://wpimportexport.com/wordpress-mcp-adapter-errors/)
- [How to connect Claude Code to WordPress via MCP](https://wpimportexport.com/connect-claude-code-to-wordpress-mcp/)
- [How to connect GitHub Copilot to WordPress via MCP](https://wpimportexport.com/connect-github-copilot-to-wordpress-mcp/)
- [How to connect OpenAI Codex to WordPress via MCP](https://wpimportexport.com/connect-codex-to-wordpress-mcp/)
- [How to use the WordPress Abilities API with AI agents](https://wpimportexport.com/how-to-use-the-wordpress-abilities-api-with-ai-agents-exports-imports-content-sync-and-backups/)
- [WordPress content inventory: export all pages with dates, authors and status](https://wpimportexport.com/wordpress-content-inventory-export/)

Import Export by RockStarLab is free on [WordPress.org](https://wordpress.org/plugins/import-export-by-rockstarlab/).
