Best Claude Code MCP Servers: Eight Workflow-Focused Picks for 2026

Key takeaways
- Best for issue-to-implementation workflows: GitHub MCP paired with Linear MCP or Jira MCP connects tracked issues with repository changes.
- Best for current technical documentation: Context7 retrieves version-specific library and framework documentation.
- Best for production debugging: Sentry brings errors, traces, and production telemetry into the development workflow.
- Best for database work: DBHub supports controlled database inspection and queries; start with read-only credentials, row limits, and query timeouts.
- Best for web research and execution: TinyFish provides Search, Fetch, website interaction, and Browser infrastructure, while Exa focuses on search and research retrieval.
- Best setup practice: Follow each server’s official guide to choose HTTP or stdio, configure authentication and scope, and verify the connection. Disable integrations that no longer save time.
Claude Code can inspect a repository and reason about its code. However, it needs an external tool to read a private GitHub issue, query Sentry, inspect a database, or retrieve current web data. A Model Context Protocol (MCP) server gives Claude Code a standardized way to discover and call external tools, such as GitHub, Sentry, databases, and web retrieval services.
This guide compares eight servers for production debugging, issue implementation, database testing, and live-web research.
Best Claude Code MCP servers at a glance
| MCP server | Best for | Remote server or locally hosted | Transport type | Pricing | Claude Code install |
|---|---|---|---|---|---|
| GitHub | Inspecting remote repositories, issues, pull requests, Actions, and release workflows | GitHub-hosted remote server or locally hosted through Docker/binary | Streamable HTTP or local stdio | No separate MCP fee; GitHub plan and usage charges may apply | claude mcp add-json github '{"type":"http","url":"https://api.githubcopilot.com/mcp","headers":{"Authorization":"Bearer YOUR_GITHUB_PAT"}}' |
| Context7 | Retrieving current, version-specific library documentation and migration guidance | Context7-hosted remote server or locally run npm package | Streamable HTTP or local stdio | Free: 1,000 calls; Pro: $10 per seat/month plus overages | npx ctx7 setup --claudeor configure HTTP/stdio manually |
| Sentry | Investigating production errors, traces, performance problems, and related code paths | Sentry-hosted remote server | Streamable HTTP with OAuth | No separate MCP fee; Sentry plan, telemetry, and Seer charges may apply | claude mcp add --transport http sentry https://mcp.sentry.dev/mcp/{organizationSlug}/{projectSlug} |
| Linear | Searching, creating, and updating issues, projects, comments, and triage status | Linear-hosted remote server | Streamable HTTP with OAuth 2.1; bearer token or API-key authentication also supported | No separate MCP fee; Linear workspace plan applies | claude mcp add --transport http linear-server https://mcp.linear.app/mcp |
| Jira MCP (Atlassian Rovo MCP) | Reading Jira tickets and Confluence context, triaging work, and updating issue status from Claude Code | Atlassian-hosted remote server | Streamable HTTP with OAuth 2.1; optional API-token authentication | Available to Atlassian Cloud customers; plan-based call limits apply | claude mcp add --transport http atlassian https://mcp.atlassian.com/v1/mcp/authv2 |
| DBHub | Exploring schemas and running guarded SQL across PostgreSQL, MySQL, MariaDB, SQL Server, and SQLite | Locally hosted or self-hosted as a remote/shared server | Local stdio or Streamable HTTP | Free and open source; database and hosting costs remain separate | claude mcp add --transport stdio dbhub -- npx @bytebase/dbhub@latest --transport stdio --dsn "<DATABASE_URI>" |
| TinyFish | Live web search, page extraction, browser sessions, and multi-step web interaction | TinyFish-hosted remote server | Streamable HTTP with OAuth 2.1 | Search and Fetch are free; Agent and Browser are metered | claude mcp add --transport http tinyfish https://agent.tinyfish.ai/mcp |
| Exa | Current web and code search, page retrieval, and multi-step research | Exa-hosted remote server or locally run npm package | Streamable HTTP or local stdio | Anonymous free tier; authenticated usage is pay-as-you-go | claude mcp add --transport http exa https://mcp.exa.ai/mcp |
Before enabling another MCP server
Install an MCP server when it removes recurring manual work or adds a distinct, safely permissioned capability. Prefer a CLI or direct API when the work is terminal-native, deterministic, high-volume, or composed into scripts.
For tools that return large logs, schemas, search results, or page content, keep responses focused. Claude Code limits each MCP tool response to 25,000 tokens by default, so useful servers should support filtering, pagination, range selection, or clear truncation. See Anthropic's tool-design guidance and Give Agents Better Context, Not More Context.
How we evaluated these MCP servers
This is a documentation-led comparison of MCP servers for Claude Code. We used the following process to make the evaluations consistent and traceable:
- Set the inclusion criteria. We selected servers that address a recurring developer workflow, provide current setup information, and expose external context or operations that Claude Code cannot access by itself.
- Prioritize primary evidence. We checked each provider’s official documentation, repository, pricing page, and Claude Code installation guidance.
- Use consistent review fields. For every server, we recorded its maintainer, supported workflow, hosting model, transport, authentication, permissions, installation method, and pricing. When information could not be verified, we treated it as undocumented rather than assuming the capability was unavailable.
- Apply a workflow-fit test. We assessed whether each server provides useful, structured access for a recurring task inside Claude Code. Each review identifies when that access justifies the setup and when the server would introduce unnecessary overlap, permissions, or operational overhead. Where a clear CLI or API alternative exists, we also note when that route may be simpler.
Users should note that some MCP servers can support more than one workflow category. The categories in this guide serve as a reference rather than fixed capability boundaries.
Workflow 1: Debug and integrate changes
Debugging slows down when repository state, library documentation, and production telemetry live outside Claude Code. These MCP servers bring the missing context into the same session, but their permissions differ sharply.
GitHub MCP

Best for: Issue implementation, pull-request review, CI diagnosis, and release work.
Workflow friction: Developers repeatedly switch between a local repository and remote GitHub issues, pull requests, or Actions results.
What it adds: GitHub MCP lets Claude Code inspect remote repositories, issues, pull requests, and Actions data alongside the local codebase. Optional write tools can create or update issues and pull requests.
Access and security:
- Authentication: The hosted setup shown below uses a PAT in an authorization header. GitHub also documents local OAuth through Docker or a native binary.
- Permissions: Use a narrowly scoped fine-grained PAT and enable GitHub MCP's read-only mode when Claude only needs context.
- Write controls: Require confirmation for high-impact actions such as merging pull requests or triggering workflows.
Install and verify: For Claude Code 2.1.1 or later, GitHub documents this hosted setup:
claude mcp add-json github '{"type":"http","url":"https://api.githubcopilot.com/mcp","headers":{"Authorization":"Bearer YOUR_GITHUB_PAT"}}'
claude mcp list
claude mcp get github
Protect the resulting local configuration because it contains the authorization header. If persistent PAT storage is unacceptable, use GitHub's documented local OAuth setup. See the Claude Code installation guide for Docker, binary, Windows, and older-Claude alternatives.
Pricing: The server is open source and has no separate MCP fee. GitHub accounts, Actions, Codespaces, and Copilot remain subject to their own plans and usage charges.
Use it when: Remote GitHub state is part of recurring issue-to-branch, pull-request, CI, or release workflows.
Skip it when: The work is local-only or occasional gh commands already cover the workflow with a smaller permission surface.
Example workflow: Triage an issue, inspect its linked pull request and failed checks, patch the local branch, then draft an update for approval.
Official documentation: GitHub MCP Server and server security configuration.
Context7 MCP

Best for: Version-specific library documentation and migration guidance.
Workflow friction: Claude Code can produce outdated APIs or invalid syntax when a framework version has moved beyond its training data.
What it adds: Context7 resolves a library and retrieves current, version-specific documentation or code examples inside the coding session. Claude receives a grounded reference for migrations, unfamiliar SDKs, and fast-moving frameworks without requiring pasted documentation.
Access and security:
- Permissions: Context7 is retrieval-only; it cannot edit the repository or execute infrastructure actions.
- Data sent: It receives a library identifier and a Claude-formulated documentation query, not the full prompt or source files.
- Data handling: Context7 stores anonymized queries and uses external models for reranking. Remove proprietary identifiers from searches, or use Enterprise controls when retention or third-party processing is unacceptable.
Install and verify: Run the official setup flow, choose MCP mode, and complete the OAuth device flow:
npx ctx7 setup --claudeAlternatively, install the Claude Code plugin with /plugin marketplace add upstash/context7 followed by /plugin install context7@context7-marketplace. Restart Claude Code and make one explicit Context7 library query; see the exact options in the Context7 Claude Code guide.
Pricing: Free includes 1,000 API calls per month. Pro costs $10 per seat per month and includes 5,000 calls per seat, with additional calls listed at $10 per 1,000; Enterprise is custom-priced. Check the current Context7 plans.
Use it when: You regularly implement against rapidly changing libraries, versioned APIs, or migration guides.
Skip it when: The work concerns proprietary business logic, stable standard libraries, or a short edit where a documentation lookup adds more context than value.
Example workflow: Check the current Next.js middleware API during an upgrade or retrieve documented Supabase row-level security syntax before generating a migration.
Official documentation: Context7 for Claude Code and Context7 data privacy.
Sentry MCP

Best for: Production-error diagnosis, trace investigation, and performance debugging.
Workflow friction: Diagnosing a production failure often means leaving the terminal to locate the right issue, stack trace, event, breadcrumb, or trace in Sentry.
What it adds: Sentry MCP lets Claude Code search production errors and performance data, inspect issue context, and connect runtime evidence to files open locally. Its Claude plugin can delegate Sentry-heavy investigation to a focused subagent.
Access and security:
- Authentication: The hosted server uses OAuth. The self-hosted stdio route requires a Sentry user token with documented read and write scopes.
- Scope: Constrain the hosted URL to one organization and project whenever possible; unscoped connections expose broader discovery tools.
- Write controls: Disable unused skills and require review for changes. A debugging MCP should not be assumed to be read-only.
Install and verify: Sentry offers both a direct MCP connection and a Claude Code plugin:
claude mcp add --transport http sentry https://mcp.sentry.dev/mcp/{organizationSlug}/{projectSlug}
Or run Claude plugin marketplace add getsentry/sentry-mcp and claude plugin install sentry-mcp@sentry-mcp. Open /mcp, complete OAuth, and confirm that Sentry tools appear; see the Sentry MCP setup page for scoping and self-hosted options.
Pricing: MCP access is included on Sentry's $0 single-user Developer plan. Team starts at $26 per month and Business at $80 per month when billed annually with default data. Telemetry overages are usage-based, and Seer is a separate $40-per-active-contributor monthly add-on. See Sentry pricing and Seer billing details.
Use it when: Production issues, traces, or performance regressions are recurring inputs to the coding workflow.
Skip it when: The project does not emit Sentry telemetry, another observability platform is authoritative, or an occasional issue URL is sufficient.
Example workflow: Pull recent events for a production issue, trace the failing code path locally, draft a fix, and summarize the evidence for review.
Official documentation: Sentry MCP repository and Sentry MCP service.
Workflow 2: Triage and update issues
Issue triage becomes fragmented when the report, acceptance criteria, and status live in a tracker while investigation and implementation happen in Claude Code.
Linear MCP

Best for: Issue triage, project creation, status updates, and investigation notes.
Workflow friction: Engineers repeatedly move between Linear and the terminal to read issue context, update status, or record investigation findings.
What it adds: Linear MCP lets Claude Code find, create, and update issues, projects, and comments. During triage, Claude can read the source ticket beside the code, propose the next action, and write an approved status or comment back to Linear.
Access and security:
- Authentication: The hosted server supports OAuth 2.1, bearer tokens, and Linear API keys.
- Read-only access: Use /mcp/readonly, request only the read OAuth scope, or supply a restricted read-only API key when Claude only needs context.
- Workspace separation: Keep separate authentication contexts for separate workspaces and review proposed creations or updates.
Install and verify:
claude mcp add --transport http linear-server https://mcp.linear.app/mcpOpen Claude Code, run /mcp, and complete the OAuth flow. For a read-only connection, replace the endpoint with https://mcp.linear.app/mcp/readonly; see the official Linear MCP guide.
Pricing: MCP access is available across Linear plans. Free includes 250 issues and two teams; Basic is $10 per user per month, Business is $16 per user per month when billed yearly, and Enterprise is custom. See Linear pricing.
Use it when: Issue context and status updates are part of most coding sessions or triage rotations.
Skip it when: The team works from GitHub Issues or Jira. Use Linear's read-only endpoint when Claude should investigate without changing tracker state.
Example workflow: Investigate a bug from a Linear issue, summarize the evidence, and post the approved findings back to the ticket.
Official documentation: Linear MCP server and use cases.
Atlassian Rovo MCP Server for Jira

Best for: Jira and Confluence context, ticket triage, and approved work-item updates.
Workflow friction: Jira tickets and Confluence specifications often hold the business context Claude Code needs, while the source code and implementation work remain local.
What it adds: Atlassian Rovo MCP lets Claude Code search and summarize Jira, Jira Service Management, Confluence, Bitbucket, and Compass context, then create or update supported work items and pages. It turns ticket-to-code triage into one reviewable flow.
Access and security:
- Authentication: The cloud-hosted server supports OAuth 2.1 and admin-enabled API-token authentication.
- Permissions: Every action uses the signed-in user's existing Atlassian permissions. Apply least privilege and review high-impact writes.
- Governance: Atlassian says the server does not store or cache Jira or Confluence content. Admins can apply domain controls and audit activity; the service does not currently support FedRAMP or HIPAA requirements.
Install and verify: Use Atlassian's current /mcp/authv2 endpoint. The former SSE endpoint stopped being supported after June 30, 2026.
claude mcp add --transport http atlassian https://mcp.atlassian.com/v1/mcp/authv2Run /mcp in Claude Code and complete authentication. See Atlassian’s exact Claude Code setup instructions and verification guide.
Pricing: The MCP server is available to all Atlassian Cloud customers. Free allows 500 calls per hour, Standard 1,000, and Premium or Enterprise 1,000 plus 20 per user, capped at 10,000 per hour. The external AI client is billed separately. Confirm current limits on the Rovo MCP product page.
Use it when: Jira or Confluence is the source of truth for requirements, incidents, or release work that Claude Code handles regularly.
Skip it when: The team works entirely from Linear or GitHub, or compliance policy forbids an AI client from accessing or changing internal work records.
Example workflow: Read a Jira bug and its linked Confluence acceptance criteria, implement the change locally, then add a reviewed pull-request update to the ticket.
Official documentation: Atlassian Rovo MCP getting started and access controls.
Workflow 3: Investigate application data without exposing write access
Database context helps Claude Code validate schemas, migrations, and seed data, but a convenience integration should never turn a coding prompt into unrestricted production SQL.
DBHub MCP

Best for: Guarded schema exploration, query validation, and read-only diagnostics across several database engines.
Workflow friction: Developers leave Claude Code to inspect schemas or run diagnostic SQL in a database GUI or separate terminal, then paste results back into the coding session.
What it adds: DBHub gives Claude Code a small tool surface for schema search and SQL execution across PostgreSQL, MySQL, MariaDB, SQL Server, and SQLite. Its progressive-disclosure workflow returns only the schema detail needed for the current task.
Access and security:
- Execution: The Claude Code plugin runs locally over stdio, while the machine connects directly to the database.
- Credential storage: The plugin stores the prompted DSN in Claude Code's secure storage rather than a repository configuration.
- Guardrails: The plugin enforces read-only mode and a 1,000-row cap. Also use a dedicated read-only database account, restrict network reachability, and keep TLS enabled.
Install and verify: Inside Claude Code, run:
/plugin marketplace add bytebase/dbhub
/plugin install dbhub@dbhub
Enter the DSN when prompted, then run /mcp and confirm DBHub is loaded. Manual stdio, HTTP, multi-database, SSH-tunnel, and custom-tool setups are documented in the DBHub Claude Code plugin guide and installation guide.
Pricing: DBHub is open source under the MIT license and has no software fee. You supply the database and any compute or network infrastructure used to run it.
Use it when: Schema exploration, query validation, or read-only diagnostics regularly inform code changes.
Skip it when: A native CLI covers occasional queries, or you cannot provision a least-privilege database identity.
Example workflow: Inspect a migration's target schema, validate a generated query against a development database, or diagnose production data through a read replica.
Official documentation: DBHub repository and Claude Code plugin.
Workflow 4: Research or test a live website from Claude Code
Claude Code's built-in web tools can retrieve public information, but they do not provide the same controls for rendered-page extraction, saved authenticated sessions, or repeatable website actions.
TinyFish MCP

Best for: Search, rendered-page extraction, multi-step website interaction, and managed browser sessions.
Workflow friction: Builders testing web-connected code may need to copy search results, clean page content manually, or leave Claude Code to operate dynamic and authenticated websites.
What it adds: TinyFish gives Claude Code one MCP surface for web search, rendered-page extraction, multi-step browser automation, saved-profile workflows, and managed browser sessions. Claude can move from discovering a URL to reading it or completing an interaction without switching integrations.
Access and security:
- Authentication: TinyFish MCP is remotely hosted and uses OAuth 2.1.
- Action boundary: Search and Fetch retrieve web content, while Agent and Browser can click, submit forms, and act on websites. Require approval for consequential actions.
- Authenticated workflows: Use Browser Context Profiles for saved session state. Enable Vault only for the credentials needed by the run and restrict credential items where possible.
Install and verify: Use the official installer:
npx -y install-mcp@latest https://agent.tinyfish.ai/mcp --client claude-codeThe documented manual alternative is claude mcp add --transport http tinyfish https://agent.tinyfish.ai/mcp. Open /mcp, complete OAuth, and confirm the TinyFish tools appear; see the exact TinyFish MCP integration guide.
Pricing: Search costs $0 per request and Fetch $0 per URL. Web Agent costs $0.016 per step, and Browser costs $0.002 per browser-minute on current wallet pricing; legacy credit plans differ. Re-check the MCP rates before publication.
Use it when: Claude Code repeatedly needs current search, clean content from JavaScript-heavy pages, or multi-step interaction with live websites.
Skip it when: The work stays inside the repository. Use the TinyFish CLI or API for deterministic scripts, high-volume composition, CI execution, or application-level retry and output control.
Example workflow: Find current documentation, fetch several pricing pages as clean content, test a live signup flow, or inspect an account dashboard through a saved authenticated profile.
Official documentation: TinyFish MCP integration, authentication, and the TinyFish-authored Claude Code portfolio case study.
Exa MCP

Best for: Web and code search, known-URL retrieval, and multi-step research.
Workflow friction: Built-in model knowledge cannot reliably supply recent pages, sources, or code examples needed for technical research.
What it adds: Exa MCP adds web search and clean page fetching, with optional advanced filters and an Agent tool for multi-step research and structured output. It is strongest when the workflow needs retrieval and synthesis rather than website interaction.
Access and security:
- Authentication: The hosted server works anonymously at low limits or authenticates through OAuth or an API key.
- Data processing: Exa processes search queries and fetched URLs remotely. Use OAuth or the documented API-key header instead of placing a key in the URL.
- Tool scope: Enable only the tools you need. Exa Agent and connected private data sources create a broader permission boundary than public-web search and fetch.
Install and verify: Install the official Claude plugin:
claude plugin install exa@claude-plugins-official
For MCP only, run claude mcp add --transport http exa https://mcp.exa.ai/mcp. Open /mcp, confirm web_search_exa and web_fetch_exa appear, and sign in if higher limits or Agent are needed; see the Exa MCP guide.
Pricing: Casual MCP use has an anonymous free tier. Authenticated accounts receive $20 in signup credits plus $10 monthly. Current rates list Search at $7 per 1,000 requests, Contents at $1 per 1,000 pages, and Agent from $0.012 to $1 per fixed-effort run or metered usage. See Exa pricing.
Use it when: Claude Code frequently performs web research, code-example search, or known-URL content retrieval.
Skip it when: Another search MCP already covers those jobs, or the workflow must click, authenticate, or complete a website interaction.
Example workflow: Find recent AI-agent developments, search for Python OAuth examples, or fetch a documentation URL as clean Markdown before implementing against it.
Official documentation: Exa MCP and Exa MCP repository.
How to successfully install a Claude Code MCP server
Before installing a Claude Code MCP server, identify its transport, decide where its configuration should apply, and prepare the required runtime and authentication.
Identify the transport
Use Streamable HTTP for a managed remote service. Use stdio when Claude Code starts a trusted local process through npx, uvx, Python, Docker, or another executable. SSE remains available for older integrations but is deprecated in Claude Code.
# Remote Streamable HTTP server
claude mcp add --transport http <name> <url>
# Local stdio server
# -- separates Claude Code options from the process command
claude mcp add --transport stdio <name> -- <command> [args...]Follow the transport specified in the server maintainer’s current documentation. A remote URL, local command, and legacy SSE endpoint are not interchangeable.
Choose a configuration scope
Claude Code supports three MCP scopes:
- local: The default. The server is available only to you in the current project; start here while testing.
- project: Writes the definition to a shareable .mcp.json. Use it when teammates need the same server, and never commit credentials in that file.
- user: Makes a trusted server available to you across projects.
Pass the scope explicitly when the default does not match the intended workflow:
# Share the server definition through the repository
claude mcp add --scope project --transport http <name> <url>
# Make the server available to the current user across projects
claude mcp add --scope user --transport http <name> <url>If you omit --scope, Claude Code uses local. The server will not automatically appear in your other repositories. Project-scoped servers also require workspace trust and interactive approval before Claude Code connects to them.
Prepare the runtime and authentication
Install a local stdio server’s runtime and executable in the same environment that runs Claude Code. Verify that the documented npx, uvx, Python, Docker, or binary command works locally before adding the server.
Remote servers may use OAuth, an API key, or an authorization header. Choose OAuth when available to avoid storing reusable tokens in the MCP configuration. For local servers, pass required values through the documented environment configuration:
claude mcp add \
--env API_KEY=<your-key> \
--transport stdio <name> \
-- <command> [args...]The --env value becomes part of the stored server configuration; it is not a secret manager. For shared .mcp.json files, use Claude Code's environment-variable expansion rather than committing a credential. For remote authentication, follow the maintainer's OAuth, header, or dynamic-header guidance. Start with least-privilege, read-only access where possible.
Verify and troubleshoot the connection
Setup note: A successful claude mcp add command means Claude Code wrote the configuration. It does not prove that the server started, authenticated, connected, or exposed the expected tools.
Check the server with:
# Review configured servers and their connection status
claude mcp list
# Inspect one server’s configuration and health
claude mcp get <name>Inside Claude Code, run:
/mcpUse /mcp to inspect the connection, complete OAuth, approve a pending project server, and confirm that the expected tools appear. Then test one low-risk read operation before allowing the server to create, update, or delete external data.
Conclusion
Install the smallest set of Claude Code MCP servers that removes context switching from work you perform every week. A carefully scoped GitHub, Sentry, issue-tracker, database, or live-web tool can replace repeated copying and let Claude work from current, structured evidence. An unused server only adds another capability to discover, secure, and maintain.
Verify every connection, begin read-only, constrain outputs, and require confirmation before shared-state or destructive actions. Autonomous execution is useful only when the underlying tools are reliable, observable, and permissioned for the task.
When Claude Code needs current Search, JavaScript-rendered Fetch, Agent-driven web interaction, or Browser infrastructure, connect TinyFish. Use its CLI or API instead when the workflow is deterministic, high-volume, or easier to review as code.
Frequently asked questions
What's an MCP server?
An MCP (Model Context Protocol) server is a local or remote program that exposes tools, resources, or prompts to an MCP-compatible client such as Claude Code.
Through MCP, Claude Code can send structured requests to outside systems such as issue trackers, databases, monitoring platforms, and web services, then use the returned results in the session.
How do I check whether an MCP server is connected in Claude Code?
An added message only confirms that the configuration was saved, not that the connection succeeded. Run claude mcp list to view every configured server and its connection status. A server marked Connected is available; Needs authentication, Pending approval, or Failed to connect requires further action. Run claude mcp get <server-name> for configuration and error details, or enter /mcp inside Claude Code to inspect tools and complete authentication. Source: Claude Code MCP documentation
Should I use local, project, or user scope for a Claude Code MCP server?
Use local scope when a server is private to you and needed only in the current project; this is Claude Code's default. Use project scope when the team should share the configuration through a version-controlled .mcp.json file, but never store secrets in that file. Use user scope for a trusted server you need across all projects. When servers share a name, Claude Code applies the precedence order local ’project’ user. Source: Claude Code MCP scopes
Are Claude Code MCP servers safe to install?
Not automatically. An MCP server may access external accounts, retrieve untrusted content, modify shared data, or, if it runs locally, execute with the same operating-system privileges as Claude Code. Verify the maintainer and exact installation command, start with read-only credentials, minimize OAuth scopes, keep secrets outside configuration files, and require approval for writes or destructive actions. Servers that retrieve web content also introduce prompt-injection risk. Sources: Claude Code security guidance, MCP Security Best Practices
Should I use an MCP server or a CLI with Claude Code?
Use an MCP server when Claude should discover structured tools, select the appropriate operation, and receive consistently formatted results during an interactive session. Use a CLI when the operation is deterministic, terminal-native, easy to script, or requires exact control over commands and output. A CLI is often simpler for occasional or high-volume tasks because Claude can invoke it through the shell without configuring another integration. Source: Claude Code MCP documentation
When should I choose an MCP server instead of an API for Claude Code?
Choose an MCP server when Claude Code should decide when and how to call an external capability using standardized tool definitions. Choose an API or SDK when your application (not Claude) must control the workflow through explicit code, typed inputs, retries, tests, batching, and production observability. MCP is optimized for agent-directed tool use inside compatible clients; an API is optimized for deterministic application integration and direct orchestration. Sources: MCP architecture, Claude Code MCP documentation
Where does Claude Code store global MCP servers?
Claude Code stores user-scoped, sometimes called global, MCP server definitions under the top-level mcpServers key in ~/.claude.json. On macOS, this normally resolves to /Users/USERNAME/.claude.json; on Windows, it resolves to %USERPROFILE%\.claude.json.
Check Claude Code MCP quickstart, MCP reference for details.
What should I do if an MCP server is missing or fails to connect in Claude Code?
Troubleshoot the connection one layer at a time:
- Confirm that the server was added at the expected local, project, or user scope.
- Restart Claude Code after changing its configuration.
- Approve any pending project-scoped server.
- Validate the JSON, remote endpoint, and selected transport.
- Confirm that Claude Code can find the required local runtime or executable.
- Check the credential, token scope, and accidental trailing whitespace.
- For a stdio server, confirm that -- separates Claude Code's options from the server command.
Re-add the server only after correcting the underlying configuration, runtime, authentication, or transport problem.
Where can I find more guidance on setting up MCP servers in Claude Code?
Use these current primary resources for installation cases this guide does not cover:
- Use the Claude Code MCP quickstart for Anthropic's guided setup workflow.
- Consult the full Claude Code MCP reference for transports, scopes, approvals, environment-variable expansion, tool discovery, and server status.
- Read the official MCP authorization guide for protected remote servers.
- Review the official MCP security best practices before connecting sensitive repositories, databases, production systems, or internal data.



