Connect Your Clients

Connecting Claude Desktop to Your MCP Server

⏱ 14 min

You built the server in Course 2. Now you get to talk to it. This lesson connects Claude Desktop to your WordPress site’s MCP endpoint, so a real conversation can trigger a real ability call, permission check, and result, exactly the lifecycle you read about in Course 1, now with an actual client on the other end.

What you'll learn in this lesson
Two ways to connect
Adding your server through Claude's settings UI, and the equivalent config file approach.
Authenticating with an Application Password
How to generate one and where it goes in the connection.
Confirming the tool list arrives
What a successful connection actually looks like inside Claude.
Running your first real tool call
Asking Claude, in plain language, to use an ability from your server.
What to do when it silently fails
The most common causes of a connector that "connects" but lists no tools.
Prerequisites

A WordPress site running the MCP Adapter plugin with HttpTransport enabled and at least one ability registered with meta.mcp.public set to true (from Course 2), a reachable HTTPS URL for that site, and Claude Desktop installed on your machine. You’ll also need a WordPress Application Password for the user account you want the agent to act as.

Step 1: generate an Application Password for the agent

Don’t reuse your own admin login credentials for this. Create or choose a WordPress user with only the capabilities the agent actually needs, then generate an Application Password from that user’s profile screen in wp-admin (Users → Profile → Application Passwords). WordPress gives you a one-time password string in the format xxxx xxxx xxxx xxxx xxxx xxxx, copy it immediately, it isn’t shown again.

# Context: you won't run a command for this part, it's a wp-admin screen,
# but this is the credential shape you're about to paste into Claude
username: agent-assistant
application-password: abcd 1234 efgh 5678 ijkl 9012

Step 2: find your MCP endpoint URL

Your endpoint’s shape depends on how the server was registered with create_server() in Course 2, but it always follows the same pattern the MCP Adapter uses for HTTP transport:

https://yoursite.com/wp-json/<namespace>/<route>

If you used the adapter’s example server as-is, that’s commonly something like https://yoursite.com/wp-json/mcp/mcp-adapter-default-server. Confirm the real value by checking the create_server() call in your own plugin code, the namespace and route are the second and third arguments you passed in.

Step 3: add the server to Claude Desktop

Claude Desktop supports custom MCP servers two ways. Use whichever your version of the app exposes.

Option A: through Claude's settings
1
Open Claude Desktop's settings
Look for the section for adding custom connectors or tool connections, this is usually under Settings, in an area for connectors or integrations.
2
Choose to add a custom connector
Provide your MCP endpoint URL from Step 2.
3
Provide the Authorization header
Enter your WordPress username and Application Password where the connector asks for authentication, if it offers a header field directly, use Basic auth with those credentials, or an equivalent Authorization: Bearer / Basic entry.
4
Save and let Claude connect
Claude opens a connection, sends initialize, and requests the tool list, this is the same lifecycle from Course 1.
Option B: editing the config file directly
1
Locate claude_desktop_config.json
This file lives in Claude Desktop's application support directory, its exact path varies by OS.
2
Add an entry under mcpServers
Give your server a name, a url, and a headers object carrying your Authorization credential.
3
Restart Claude Desktop
Config file changes require a full restart of the app to take effect, a reload isn't enough.
// File: claude_desktop_config.json
{
  "mcpServers": {
    "wordpress-site": {
      "url": "https://yoursite.com/wp-json/mcp/mcp-adapter-default-server",
      "headers": {
        "Authorization": "Basic YWdlbnQtYXNzaXN0YW50OmFiY2QgMTIzNCBlZmdoIDU2NzggaWprbCA5MDEy"
      }
    }
  }
}

That Authorization value is a base64-encoded username:application-password string, the same Basic auth scheme WordPress’s REST API has always used, MCP doesn’t change this, the adapter just sits on top of the normal REST layer.

# Context: generating the base64 value yourself, if your UI doesn't do it for you
echo -n "agent-assistant:abcd 1234 efgh 5678 ijkl 9012" | base64
Never paste a real Application Password into a shared file

If you’re keeping claude_desktop_config.json in a dotfiles repo or synced folder, treat it like any other secret. Anyone with that string can act as that WordPress user through your MCP server until you revoke it from the user’s profile screen.

Step 4: test it

Ask Claude something that maps directly to the ability you registered in Course 2, phrased the way a normal user would, not as a command.

You: "Check what tools you have available on my WordPress site."

A working connection shows Claude listing the tool(s) it discovered, using the label and description text from your ability registration, not raw PHP function names. If you registered a “create a draft post” ability, ask for exactly that:

You: "Create a draft post titled 'Hello from Claude' with a short intro paragraph."
Signs the connection actually works
Claude names your specific tool
Not a generic "I don't have that ability" response.
The result references real data
A post ID, a URL, or a status Claude couldn't have guessed.
Checking wp-admin confirms it
The draft actually exists in Posts, created by the agent user, not your own account.
Connected but zero tools listed

This almost always means one of three things: meta.mcp.public isn’t set to true on the ability you expected to see, the Application Password’s user lacks the capability your permission_callback checks for, or the URL you gave Claude points at the wrong namespace/route pair. Check the ability registration and the create_server() call before assuming the client is broken.

Recap

Claude Desktop connects to your WordPress MCP server the same way it connects to any remote MCP server: a URL and an Authorization header carrying your Application Password, either through the settings UI or claude_desktop_config.json. A successful connection means the tool list you registered in Course 2 shows up by name, and a natural-language request against it produces a real, verifiable change on your site.

Resources & further reading

Connecting Cursor to Your MCP Server →