🚀 The fast, Pythonic way to build MCP servers and clients. https://gofastmcp.com
  • Python 99.2%
  • JavaScript 0.5%
  • CSS 0.2%
  • HTML 0.1%
Find a file
2026-11-23 02:01:12 +00:00
.agents/skills Scale review effort to risk and require compatibility tables (#6698) 2026-11-23 01:39:28 +00:00
.github Require the assessor to answer area (#6699) 2026-11-23 02:01:12 +00:00
dev-docs Pre-4.2 polish: stale docs, examples and docstrings (#6452) 2026-11-11 17:33:54 -06:00
docs Add UsageMiddleware for per-user, per-tool usage metrics (#6510) 2026-11-23 01:30:47 +00:00
examples Bump platformdirs and markdown-it-py in lock files (#6608) 2026-11-20 18:27:16 +00:00
fastmcp_remote Pre-4.2 polish: stale docs, examples and docstrings (#6452) 2026-11-11 17:33:54 -06:00
fastmcp_slim Add UsageMiddleware for per-user, per-tool usage metrics (#6510) 2026-11-23 01:30:47 +00:00
fastmcp_tasks Add parent_task_spans option for background task traces (#6563) 2026-11-18 23:20:33 -06:00
scripts Keep a daily history of the triage floor and richer log events (#6687) 2026-11-23 00:17:50 +00:00
skills Retire alpha-only skills code and redirect experimental providers (#6279) 2026-11-03 16:25:25 -06:00
status-site Add a property-based test coverage map to the status site (#6573) 2026-11-19 02:21:37 -06:00
tests Add UsageMiddleware for per-user, per-tool usage metrics (#6510) 2026-11-23 01:30:47 +00:00
.ccignore Update .ccignore 2025-06-30 18:41:04 -04:00
.gitattributes Store text files with LF line endings (#6605) 2026-11-20 18:58:18 +00:00
.gitignore Add a property-based test harness (#6578) 2026-11-19 02:21:01 -06:00
.gitleaks.toml Add gitleaks secret scanning to prek (#5355) 2026-10-04 20:39:41 -04:00
.pre-commit-config.yaml Store text files with LF line endings (#6605) 2026-11-20 18:58:18 +00:00
.python-version Initial commit 2024-11-29 16:42:40 -05:00
AGENTS.md Draft releases from merged changelog entries (#6594) 2026-11-20 18:32:49 +00:00
CLAUDE.md docs: credit issue authors in maintainer implementations (#5410) 2026-10-04 08:07:14 -04:00
CODE_OF_CONDUCT.md Create CODE_OF_CONDUCT.md (#1523) 2025-08-16 16:28:15 -04:00
CONTRIBUTING.md docs: credit issue authors in maintainer implementations (#5410) 2026-10-04 08:07:14 -04:00
justfile Pre-4.2 polish: stale docs, examples and docstrings (#6452) 2026-11-11 17:33:54 -06:00
LICENSE Basic cleanup 2025-04-05 17:39:51 -04:00
loq.toml Pre-4.2 polish: stale docs, examples and docstrings (#6452) 2026-11-11 17:33:54 -06:00
pyproject.toml Run time-boxed property-based campaigns in CI (#6616) 2026-11-20 22:08:59 -06:00
README.md docs: rename Horizon to FastMCP Gateway in current docs (#5653) 2026-10-30 09:13:34 -07:00
renovate.json Read composite action inputs from env and pin actions by digest (#6168) 2026-10-30 21:05:07 +00:00
SECURITY.md fix: require patched certifi trust stores (#5945) 2026-10-20 17:27:07 -05:00
uv.lock Bump platformdirs and markdown-it-py in lock files (#6608) 2026-11-20 18:27:16 +00:00

FastMCP Logo

FastMCP 🚀

Move fast and make things.

Made with 💙 by Prefect

Docs Discord PyPI - Version TypeScript Tests License

prefecthq%2Ffastmcp | Trendshift


The Model Context Protocol (MCP) connects LLMs to tools and data. FastMCP is a full MCP application framework for servers, clients, and interactive apps. A server starts with ordinary Python:

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 your logic, and the MCP part just works: with FastMCP, best practices are built in.

That's why FastMCP is the standard framework for working with MCP. FastMCP 1.0 was incorporated into the official MCP Python SDK in 2024. Today, the actively maintained standalone project is downloaded a million times a day, and some version of FastMCP powers 70% of MCP servers across all languages.

FastMCP has three pillars:

Servers
Servers

Expose tools, resources, and prompts to LLMs.
Apps
Apps

Give your tools interactive UIs rendered directly in the conversation.
Clients
Clients

Connect to any MCP server — local or remote, programmatic or CLI.

Servers wrap your Python functions into MCP-compliant tools, resources, and prompts. Clients connect to any server with full protocol support. And Apps give your tools interactive UIs rendered directly in the conversation.

Building in TypeScript? FastMCP for TypeScript is the official counterpart, built and maintained by the same team. Same pillars, same ideas, npm install @prefecthq/fastmcp-ts.

Ready to build? Start with the installation guide or jump straight to the quickstart.

Scale MCP with FastMCP Gateway

FastMCP handles the MCP application layer. FastMCP Gateway is the enterprise MCP gateway for scaling servers and tools across teams, with centralized governance over how they are deployed, discovered, secured, and used.

FastMCP and FastMCP Gateway are built by the same team at Prefect.

Deploy FastMCP servers from GitHub with branch previews and instant rollback. Create a private registry of every MCP your company uses. Secure access with SSO and tool-level RBAC. Get audit logs, observability, and governance across your MCP stack. Remix approved tools into purpose-built endpoints for teams and agents.

Start with FastMCP. Scale with FastMCP Gateway →

Installation

We recommend adding FastMCP to your project with uv:

uv add fastmcp

For full installation instructions, including verification and upgrading, see the Installation Guide.

Upgrading? We have guides for:

📚 Documentation

FastMCP's complete documentation is available at gofastmcp.com, including detailed guides, API references, and advanced patterns.

Documentation is also available in llms.txt format, which is a simple markdown standard that LLMs can consume easily:

  • llms.txt is essentially a sitemap, listing all the pages in the documentation.
  • llms-full.txt contains the entire documentation. Note this may exceed the context window of your LLM.

Give your coding agent llms.txt as its starting point. See Coding Agents for version-matched documentation and the optional server authoring skill.

Community: Join our Discord server to connect with other FastMCP developers and share what you're building.

Contributing

Start with CONTRIBUTING.md for accepted contributions and the issue-assignment workflow, then follow the Contributing Guide for setup and validation. Agents should read AGENTS.md.