home / mcp / connect to salesforce mcp server
Guides end users through installing Salesforce CLI, authenticating with OAuth, and connecting Claude Desktop to Salesforce.
Configuration
View docs{
"mcpServers": {
"jake-hebert-connect-to-salesforce-mcp": {
"command": "npx",
"args": [
"-y",
"@digitalrupix/connect-to-salesforce-mcp"
],
"env": {
"SALESFORCE_ORG_ALIAS": "mcp-server-connect",
"SALESFORCE_INSTANCE_URL": "YOUR_SALESFORCE_INSTANCE_URL",
"SALESFORCE_CONNECTION_TYPE": "Salesforce_CLI"
}
}
}
}You can connect Claude Desktop to Salesforce using an integrated setup assistant that guides you through installing the Salesforce CLI, authenticating securely, and saving your connection. This MCP server handles everything from checking a Salesforce CLI installation to opening a browser for OAuth and verifying your connection, so you can start using Salesforce features in Claude with no technical expertise.
Open Claude Desktop and ask Claude to help you connect to Salesforce. Say or type a request like “Help me set up Salesforce” or “Connect to Salesforce.” Claude will guide you through each step, including installing the Salesforce CLI if needed, starting a secure login in your browser, and confirming the connection. When the setup finishes, restart Claude Desktop if prompted and you’re ready to use Salesforce within Claude.
Prerequisites you need on your computer: Node.js 18.0.0 or higher, NPM (comes with Node.js), and Claude Desktop.
# Optional: install the MCP package globally
npm install -g @digitalrupix/connect-to-salesforce-mcp
# If you are an administrator deploying to many machines, place the configuration as needed per user
# Example configuration paths for Claude Desktop per operating system (for admins):
# Mac: ~/Library/Application Support/Claude/claude_desktop_config.json
# Windows: %APPDATA%\Claude\claude_desktop_config.json
# Linux: ~/.config/Claude/claude_desktop_config.jsonThis MCP server uses two internal MCP configurations to connect to Salesforce: one to initiate and manage the connection process, and another to handle the actual Salesforce CLI integration. The environment variables shown below control the Salesforce instance URL and the org alias used for the authenticated connection.
{
"mcpServers": {
"connect-to-salesforce": {
"command": "npx",
"args": ["-y", "@digitalrupix/connect-to-salesforce-mcp"],
"env": {
"SALESFORCE_INSTANCE_URL": "https://your-org.my.salesforce.com",
"SALESFORCE_ORG_ALIAS": "mcp-server-connect"
}
},
"salesforce": {
"command": "npx",
"args": ["-y", "@tsmztech/mcp-server-salesforce"],
"env": {
"SALESFORCE_CONNECTION_TYPE": "Salesforce_CLI",
"SALESFORCE_INSTANCE_URL": "https://your-org.my.salesforce.com"
}
}
}
}Credentials are stored by the Salesforce CLI in secure storage and never written in plain text within config files. Each user authenticates with their own Salesforce account, and the browser-based OAuth flow ensures credentials remain protected. If you ever need to restart the setup, you can simply re-run the process from Claude and re-authenticate as needed.
If you encounter problems, perform these checks in order: ensure Claude Desktop is fully closed before adjustments, verify Salesforce CLI is installed, and confirm the correct instance URL and alias are configured.
If the browser does not open automatically during login, try the manual login command shown in the setup flow and ensure pop-ups are allowed for the browser. If issues persist, contact your IT administrator for assistance.
Admins can deploy the Claude Desktop configuration to users’ machines and provide the following environment values for consistent setup across endpoints.
Key points to remember:
- Both MCP servers use the same Salesforce instance URL for a consistent experience.
- The org alias should match between the setup MCP and the Salesforce MCP configuration.
- End users must have Node.js and npm installed on their machines.Guides the user through installation, OAuth login in the browser, and verification of the Salesforce connection.
Opens the browser for secure OAuth authentication and handles the login flow.
Checks the Salesforce org status to confirm a successful connection and stores credentials securely.