How-To Guide

How to Use MCP Servers with Claude Code

Connect Claude Code to external tools and APIs using MCP servers. GitHub, Slack, databases, and more.

How to Use MCP Servers with Claude Code

1

Understand MCP servers

MCP (Model Context Protocol) servers extend Claude Code with external tools — databases, APIs, file systems, and services. They let Claude interact with tools beyond your local codebase.

2

Configure MCP servers in settings

Add MCP server configurations to your `.claude/settings.json` or project-level `.claude.json`. Each server specifies a command to run and optional environment variables.

3

Use the /mcp command

Run `/mcp` in Claude Code to see connected MCP servers and their available tools. This helps you understand what capabilities are available.

4

Let Claude discover and use tools

When you ask Claude to perform a task, it automatically discovers relevant MCP tools. For example, if a GitHub MCP is configured, Claude can create PRs, read issues, and manage repos.

Pro tips

  • *

    Start with officially supported MCP servers from the Anthropic MCP registry

  • *

    MCP servers run locally — your data doesn't pass through additional third parties

  • *

    Use `scope: project` vs `scope: user` to control which MCP servers are available where

More Claude Code guides

Explore more