Software Development

Can Salesforce Hosted MCP Servers be used with Claude Desktop or Cursor for local development?

JA Asked by James Wilson · 03-11-2025
0 upvotes 9,379 views 0 comments
The question

I've seen some tutorials where people connect their IDEs like Cursor or the Claude Desktop app to local MCP servers. Is it possible to point these local clients to a "Hosted" MCP server inside a Salesforce Sandbox? I'd love to use natural language to query my org's metadata and run Apex tests directly from my coding environment using this protocol.

3 answers

0
JE
Answered on 05-11-2025

Yes, this is one of the coolest use cases for the Salesforce DX MCP Server! You can configure your claude_desktop_config.json or Cursor's MCP settings to point to the Salesforce endpoint. You'll need the SALESFORCE_ACCESS_TOKEN and the INSTANCE_URL. Once connected, you can literally ask Claude, "Show me all the fields in the Account object," or "Run the AccountTriggerTest class and show me the coverage." It uses the Tooling API under the hood but abstracts it through the MCP standard, making it feel like you're just chatting with your codebase. It saves a ton of time during the initial discovery phase of a project.

0
TH
Answered on 08-11-2025

Does this setup require a permanent connection, or can it work with Scratch Orgs? I’m worried that if I’m constantly spinning up new environments, updating the access tokens in my local JSON config files will become a massive headache for my dev team.

KE 10-11-2025

Thomas, you can actually automate the token update using a simple shell script or a Salesforce CLI plugin. When you run sf org display, you can pipe the access token directly into your MCP config. This way, your team stays synced with whatever Scratch Org is currently set as the default. It’s a very agile way to handle development, especially when you're iterating on complex AI prompts that need real-time metadata.

0
ME
Answered on 12-11-2025

It works great with Cursor. I’ve been using it to generate SOQL queries based on natural language descriptions of the relationships, and it's remarkably accurate.

JE 14-11-2025

I agree with Megan. The "relationship support" in the Salesforce MCP implementation is top-notch. It handles parent-child subqueries much better than a generic LLM would without that specific schema context.

Share your thoughts

Your email address will not be published. Required fields are marked (*)

Professional Counselling Session

Still have questions?
Schedule a free counselling session

Our experts are ready to help you with any questions about courses, admissions, or career paths. Get personalized guidance from industry professionals.

Request a Call Back

Search Online

We Accept

We Accept

Follow Us

"PMI®", "PMBOK®", "PMP®", "CAPM®" and "PMI-ACP®" are registered marks of the Project Management Institute, Inc. | "CSM", "CST" are Registered Trade Marks of The Scrum Alliance, USA. | COBIT® is a trademark of ISACA® registered in the United States and other countries.

Book Free Session