Setting Up Your Environment
What you will learn
- Install the Python MCP SDK using pip or uv
- Install Claude Desktop for testing your servers locally
- Verify your setup works with a minimal "hello" server
What you need
Before writing any code, make sure you have these three things:
- Python 3.10 or newer — run
python --versionto check - pip or uv — either package manager works
- Claude Desktop (free) — this is your MCP client for local testing
Install the MCP SDK
With pip:
pip install mcp
With uv (faster, recommended if you use it):
uv add mcp
Verify with a minimal server
Create a file called hello_mcp.py anywhere on your machine:
from mcp.server.fastmcp import FastMCP
mcp = FastMCP("Hello Server")
@mcp.tool()
def greet(name: str) -> str:
"""Say hello to someone by name."""
return f"Hello, {name}! MCP is working."
if __name__ == "__main__":
mcp.run()
Run it:
python hello_mcp.py
If the server starts and waits silently — no output, no error — your setup is correct. Press Ctrl+C to stop.
Install Claude Desktop
Download it from claude.ai/download. Once installed, it will be your MCP host — the application that connects to your servers and lets Claude use your tools.
You do not need a paid Claude plan to use Claude Desktop with local MCP servers.
Chapter summary
- Python 3.10+, pip or uv, and Claude Desktop are all you need to get started
pip install mcpinstalls the SDK with FastMCP included- A server that starts silently and waits is working correctly
- Claude Desktop is your free, local MCP host for testing
Check your understanding
- How do you verify that Python 3.10+ is installed?
- What does it mean when your MCP server starts and produces no output?
- What is the difference between the raw MCP SDK and FastMCP?