> For the complete documentation index, see [llms.txt](https://help.sdocs.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.sdocs.com/sdocs/automation-and-document-lifecycle/configure-s-docs-for-mcp/configuring-mcp-clients/connect-to-claude.md). Agents can also search and read this documentation through its [MCP server](https://help.sdocs.com/~gitbook/mcp).

# Connect to Claude

Connecting Claude to a Salesforce Hosted Model Context Protocol (MCP) server allows your AI assistant to interact with Salesforce logic and assets. These instructions apply to Claude.ai and the Claude Desktop app.

{% hint style="info" %}
Claude Code automatically inherits this connection. Once you add the connector, it becomes available to Claude Code without additional configuration.
{% endhint %}

#### Prerequisites

Before starting, ensure you have:

* An active Claude.ai account or the Claude Desktop app.
* The consumer key for your registered [*External Client App* (ECA) in Salesforce.](https://help.sdocs.com/sdocs/automation-and-document-lifecycle/configure-s-docs-for-mcp/set-up-salesforce-hosted-mcps/create-an-external-client-app.md)
* The name of your available MCP server.

***

### Step-by-step Setup Instructions

1. In the left sidebar of Claude, click **Customize**.
2. Click **Connectors**, then click **Add** and select **Add custom connector**.
3. In the connector name field, **enter a name for the connector.**

{% hint style="info" %}
This will be the name appears in your connectors list.
{% endhint %}

4. Enter the server URL, substituting `<SERVER-NAME>` with your specific server name:

**Production orgs:** `https://api.salesforce.com/platform/mcp/v1/<SERVER-NAME>`

**Sandbox** or **scratch orgs:** `https://api.salesforce.com/platform/mcp/v1/sandbox/<SERVER-NAME>`

**Example:**

To use the `platform/sobject-all` server in a sandbox org, enter:

`https://api.salesforce.com/platform/mcp/v1/sandbox/platform/sobject-all`

5. Click **Continue**.
6. Under *OAuth client*, select **Use your own OAuth client**.
7. In the *OAuth Client ID* field, paste the consumer key from your *External Client App*.

{% hint style="info" %}
If you did not save the consumer key from the configuration step, navigate to the ECA Settings to copy the key:

<img src="https://1548664070-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FWKNnJmhJBQwhdk5WBFsi%2Fuploads%2Fgit-blob-dd15f4d1312266d9c65bcb979243035f2b124d7a%2FScreenshot%202026-10-01%20at%2011.42.51%E2%80%AFAM.png?alt=media" alt="" data-size="original">

• Enter the public identifier from your app's OAuth settings — **do not use an API key or token.**

• Leave *OAuth Client Secret* blank unless your authorization server explicitly requires one.
{% endhint %}

6. Next to your newly created connector, click **Connect**.

{% hint style="info" %}
Claude redirects to the Salesforce org containing your *External Client App*. If you are already logged in, the user challenge is skipped, obtaining an access token and sending it back to Claude.
{% endhint %}

### Configuring tool permissions (optional)

Once authentication completes successfully, click Configure next to the connector to adjust permission settings for the available tools on your selected MCP server.

### Testing the connection

To test the client connection to the MCP server, submit a natural language request through Claude’s chat interface and verify that it returns the expected response.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://help.sdocs.com/sdocs/automation-and-document-lifecycle/configure-s-docs-for-mcp/configuring-mcp-clients/connect-to-claude.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
