PrefectHQ/fastmcp

🚀 The fast, Pythonic way to build MCP servers and clients.
omit in toc
FastMCP 🚀
Move fast and make things.
Made with 💙 by Prefect
The Model Context Protocol (MCP) connects LLMs to tools and data. FastMCP gives you everything you need to go from prototype to production:
from fastmcp import FastMCP
mcp = FastMCP("Demo 🚀")
@mcp.tool def add(a: int, b: int) -> int: """Add two numbers""" return a + b
if name == "main": mcp.run()
Why FastMCP
Building an effective MCP application is harder than it looks. FastMCP handles all of it. Declare a tool with a Python function, and the schema, validation, and documentation are generated automatically. Connect to a server with a URL, and transport negotiation, authentication, and protocol lifecycle are managed for you. You focus on you…