📚Academy
likeone
online
Module 3 · Lesson 7

Connecting to Claude

Walk through the four phases of connecting an MCP server to Claude Desktop or Claude Code -- from installation to live tool usage. Click each phase tab below to walk through the process step by step.

1Install
2Configure
3Discover
4Use

Phase 1: Install Your MCP Server

In this phase, you get the MCP server code onto your machine. MCP servers are typically Node.js packages published to npm, or standalone scripts you run locally. Installation is straightforward:

📦

Option A: Install from npm

Most community MCP servers are published as npm packages. Install globally or use npx:

Terminalbash
# Install a community MCP server globally npm install -g @modelcontextprotocol/server-filesystem # Or use npx to run without installing npx @modelcontextprotocol/server-filesystem /path/to/allowed/dir
💻

Option B: Run your own server

If you built a custom server (like in Lesson 4), you can run it directly with Node or compile it first:

Terminalbash
# Run a TypeScript server with tsx npx tsx my-server.ts # Or compile and run tsc my-server.ts && node my-server.js

Phase 2: Configure in Claude

In this phase, you tell Claude where to find your server by editing a config file. This JSON file maps server names to the commands that launch them.

📄

Claude Desktop Config Location

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json

claude_desktop_config.jsonJSON
{ "mcpServers": { "filesystem": { "command": "npx", "args": [ "-y", "@modelcontextprotocol/server-filesystem", "/Users/you/projects" ] }, "database": { "command": "node", "args": ["./my-db-server.js"], "env": { "DB_URL": "postgresql://localhost/mydb" } } } }
🔧

Key Config Fields

command — The program to run (node, npx, python, etc.). This is what launches your server.
args — Extra information passed to the command, like which directory to access or which server package to use.
env — Secret values the server needs to work, like API keys or database connection strings. These stay on your machine.

🔒

This lesson is for Pro members

Unlock all 300+ lessons across 30 courses with Academy Pro. Founding members get 90% off — forever.

Already a member? Sign in to access your lessons.

Academy
Built with soul — likeone.ai