> ## Documentation Index
> Fetch the complete documentation index at: https://mcpverified.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Comparison of MCP Server Frameworks

> A comprehensive comparison between TypeScript libraries for creating Model Context Protocol (MCP) servers, for both local and remote deployments.

export const GitHubPackageCards = ({packages}) => <CardGroup>
    {packages.map(pkg => {
  const repoPath = `${pkg.owner}/${pkg.repo}`;
  const npmPackage = pkg.npmPackage || pkg.repo;
  return <Card key={repoPath} title={pkg.title || npmPackage} href={`https://github.com/${repoPath}`} img={`https://opengraph.githubassets.com/1/${repoPath}`}>
          <img alt="GitHub Repo stars" src={`https://img.shields.io/github/stars/${repoPath}?style=flat`} />
          <img alt="GitHub License" src={`https://img.shields.io/github/license/${repoPath}?style=flat`} />
          <img alt="GitHub last commit" src={`https://img.shields.io/github/last-commit/${repoPath}?style=flat`} />
          {pkg.npmPackage && <img alt="NPM Downloads" src={`https://img.shields.io/npm/dw/${npmPackage}?style=flat`} />}
        </Card>;
})}
  </CardGroup>;

# <Icon icon="chart-bar" iconType="solid" color="#3B82F6" /> MCP Server Frameworks Comparison

<Callout type="info">
  <Icon icon="info-circle" iconType="solid" /> The Model Context Protocol (MCP) is an open standard that standardizes how applications provide context to Large Language Models (LLMs). It follows a client-server architecture that enables AI models to safely access specific data and capabilities. MCP allows Hosts (like IDEs or AI tools) to communicate with Servers (lightweight programs exposing capabilities) via Clients, accessing local or remote data sources securely.
</Callout>

## <Icon icon="bolt" iconType="solid" /> Quick Selection Guide

This guide helps you quickly choose a framework based on its primary strengths:

<Accordion title="@modelcontextprotocol/sdk" icon="code" iconType="solid">
  **Choose if:** You need the official, spec-compliant implementation with maximum control. Ideal for foundational work or when strict adherence is paramount.
</Accordion>

<Accordion title="Cloudflare agents" icon="cloud" iconType="solid">
  **Choose if:** You're deploying stateful AI agents, especially on Cloudflare's edge network. Benefits from Cloudflare integration and managed infrastructure.
</Accordion>

<Accordion title="fastmcp" icon="meter" iconType="solid">
  **Choose if:** Session management, streaming, and production-ready features (like auth, logging) are critical. Offers a rich feature set out-of-the-box.
</Accordion>

<Accordion title="mcp-framework" icon="laptop-code" iconType="solid">
  **Choose if:** You prefer convention-over-configuration, rapid development, and CLI tooling. Built on the official SDK, focusing on developer experience.
</Accordion>

<GitHubPackageCards
  packages={[
{
  owner: "modelcontextprotocol",
  repo: "typescript-sdk",
  title: "@modelcontextprotocol/sdk",
  npmPackage: "@modelcontextprotocol/sdk"
},
{
  owner: "cloudflare",
  repo: "agents",
  title: "Cloudflare agents",
  npmPackage: "agents"
},
{
  owner: "punkpeye",
  repo: "fastmcp",
  title: "fastmcp",
  npmPackage: "fastmcp"
},
{
  owner: "QuantGeekDev",
  repo: "mcp-framework",
  title: "mcp-framework",
  npmPackage: "mcp-framework"
}
]}
/>

## <Icon icon="list" iconType="solid" /> Feature Comparison

Compare the frameworks side-by-side across various features.

<Tabs items={['Summary Grid', 'Detailed Feature Table']}>
  <Tab title="Summary">
    | Feature                       | `@modelcontextprotocol/sdk` | `Cloudflare agents`         | `fastmcp`                | `mcp-framework`               |
    | :---------------------------- | :-------------------------- | :-------------------------- | :----------------------- | :---------------------------- |
    | **Primary Goal**              | Core MCP Implementation     | Stateful Edge AI Agents     | MCP Server w/ Sessions   | DX-focused MCP Framework      |
    | **MCP Compliance**            | Official Standard           | High (Agent-focused)        | High                     | High (Uses official SDK)      |
    | **Architecture**              | Low-level Primitives        | Actor Model (Workers)       | Session-centric          | Convention over Config        |
    | **Transports**                | `stdio`, `HTTP (SSE)`       | `HTTP (SSE)`, `WebSockets`  | `SSE`, `stdio`           | `stdio`, `SSE`, `HTTP Stream` |
    | **State Management**          | Manual                      | Built-in (Durable Objects)  | Session-based            | Manual/Per-Request            |
    | **Authentication**            | Manual                      | Via Cloudflare Access/OAuth | Built-in                 | Built-in (SSE)                |
    | **Developer Experience (DX)** | Foundational                | High (Integrated CF)        | High (Specific Features) | High (CLI, Conventions)       |
    | **CLI Tooling**               | None                        | `wrangler`                  | Testing utilities        | Yes (`mcp`)                   |
    | **Deployment**                | Local/Any Server            | Cloudflare Workers          | Local/Any Server         | Local/Any Server              |
  </Tab>

  <Tab title="Detailed Comparison">
    | Feature                       | @modelcontextprotocol/sdk | Cloudflare agents     | fastmcp    | mcp-framework   | Notes                                                               |
    | ----------------------------- | ------------------------- | --------------------- | ---------- | --------------- | ------------------------------------------------------------------- |
    | **Protocol Compliance**       |                           |                       |            |                 |                                                                     |
    | MCP Specification Conformance | ◯                         | ◯                     | ◯          | ◯               | All implementations follow MCP spec                                 |
    | Tools Support                 | ◯                         | ◯                     | ◯          | ◯               |                                                                     |
    | Resources Support             | ◯                         | △                     | ◯          | ◯               | Cloudflare: Limited support, coming soon                            |
    | Prompts Support               | ◯                         | △                     | ◯          | ◯               | Cloudflare: In development                                          |
    | Sampling Support              | ◯                         | △                     | ◯          | △               | `fastmcp`: Explicit sampling support                                |
    | **Transport Options**         |                           |                       |            |                 |                                                                     |
    | `stdio`                       | ◯                         | ✗                     | ◯          | ◯               | Cloudflare: Designed for remote use only                            |
    | `HTTP/SSE`                    | ◯                         | ◯                     | ◯          | ◯               | Standard remote transport                                           |
    | Streamable HTTP               | △                         | ◯                     | △          | △               | Evolving transport method, `mcp-framework` has experimental support |
    | WebSocket Support             | ✗                         | △                     | ✗          | ✗               | Cloudflare: Planned for future                                      |
    | **Deployment**                |                           |                       |            |                 |                                                                     |
    | Local Deployment              | ◯                         | ✗                     | ◯          | ◯               | `agents` requires remote adapter for local                          |
    | Remote Deployment             | ◯                         | ◯                     | ◯          | ◯               |                                                                     |
    | Cloud Integration             | △                         | ◯                     | △          | ✗               | Cloudflare: Native Workers integration                              |
    | **Authentication & Security** |                           |                       |            |                 |                                                                     |
    | Basic Authentication          | Manual                    | Via Cloudflare Access | ◯          | △ (SSE Only)    | `fastmcp`: Built-in support                                         |
    | OAuth Support                 | Manual                    | ◯                     | Manual     | ✗               | Cloudflare: Built-in OAuth provider                                 |
    | Session Management            | Manual                    | ◯ (Durable Objects)   | ◯          | Manual          | `fastmcp`: Core feature                                             |
    | **Developer Experience**      |                           |                       |            |                 |                                                                     |
    | Documentation Quality         | ◯                         | ◯                     | ◯          | △               | `mcp-framework`: Improving                                          |
    | Examples & Templates          | ◯                         | ◯                     | ◯          | △               | `mcp-framework`: Relies on CLI                                      |
    | TypeScript Support            | ◯                         | ◯                     | ◯          | ◯               | All are TS-first                                                    |
    | Type Safety                   | ◯                         | ◯                     | ◯          | ◯               | Strong typing via Zod/TS                                            |
    | CLI Testing Tools             | ✗                         | ◯ (`wrangler`)        | ◯          | ◯ (`mcp`)       | `mcp-framework` CLI for scaffolding/running                         |
    | Hot Reloading                 | ✗                         | ◯ (`wrangler dev`)    | △          | △ (`mcp dev`)   | Framework dependent                                                 |
    | **Features**                  |                           |                       |            |                 |                                                                     |
    | Progress Notifications        | ◯                         | △                     | ◯          | △               |                                                                     |
    | Error Handling                | Basic                     | Framework-level       | ◯          | Framework-level | `fastmcp`: Comprehensive handling                                   |
    | Logging                       | Basic                     | Integrated (CF)       | ◯          | Basic           | `fastmcp`: Built-in logging                                         |
    | CORS Support                  | Manual                    | ◯                     | ◯          | △ (SSE Only)    | Necessary for web clients                                           |
    | Image Content Support         | ◯                         | ◯                     | ◯          | △               | Standard in MCP                                                     |
    | Automated SSE Pings           | Manual                    | ◯                     | ◯          | ✗               | Keep-alive for SSE                                                  |
    | Cancellation Support          | ◯                         | ◯                     | ◯          | △               | Standard in MCP                                                     |
    | **Ecosystem**                 |                           |                       |            |                 |                                                                     |
    | Community Support             | ◯ (Official)              | ◯ (Cloudflare)        | ◯ (Active) | △ (Growing)     |                                                                     |
    | Active Development            | ◯                         | ◯                     | ◯          | ◯               | All are actively maintained                                         |
    | Production Readiness          | ◯                         | ◯                     | ◯          | ◯               | All are used in production                                          |
    | External Services Integration | Manual                    | ◯ (Workers)           | Manual     | Manual          | Cloudflare shines here                                              |

    **Legend:**

    * ◯ **Full support / Built-in:** Feature is well-implemented and documented.
    * △ **Partial / Manual / Basic:** Feature exists but may require manual setup, is basic, or is under development.
    * ✗ **No support:** Feature is not supported or not applicable.
  </Tab>
</Tabs>

## <Icon icon="server" iconType="solid" /> Deployment Models: Local vs. Remote

Understand the trade-offs between running your MCP server locally or remotely.

<Tabs items={['Local MCP Servers', 'Remote MCP Servers']}>
  <Tab title="Local MCP Servers">
    ### <Icon icon="desktop" iconType="solid" /> Local MCP Servers

    Run directly on the user's machine, typically communicating via `stdio`.

    <Callout type="success">
      <Icon icon="check-circle" iconType="solid" /> **Advantages**

      * **Direct Data Access:** Easily access local files, databases, and system resources.
      * **Low Latency:** No network overhead for communication.
      * **Enhanced Privacy:** Sensitive data remains on the user's device.
      * **Simplified Security:** Often bypasses complex remote authentication needs.
      * **Offline Capability:** Functions without an internet connection.
    </Callout>

    <Callout type="warning">
      <Icon icon="exclamation-triangle" iconType="solid" /> **Disadvantages**

      * **Limited Scope:** Only accessible on the machine where it's installed.
      * **Installation Burden:** Requires setup on each user's device.
      * **Distribution Challenges:** Harder to distribute and update compared to web services.
      * **Scalability Limits:** Bound by the resources of the local machine.
    </Callout>

    **Primary Communication Method**: <Icon icon="terminal" iconType="solid" /> `stdio` (Standard Input/Output)
    **Best suited for**: `@modelcontextprotocol/sdk`, `fastmcp`, `mcp-framework`
  </Tab>

  <Tab title="Remote MCP Servers">
    ### <Icon icon="globe" iconType="solid" /> Remote MCP Servers

    Hosted on a server or cloud platform, accessible over the network, typically via `HTTP/SSE`.

    <Callout type="success">
      <Icon icon="check-circle" iconType="solid" /> **Advantages**

      * **Accessibility:** Reachable from any device with internet access.
      * **Centralized Management:** Easier deployment, updates, and maintenance.
      * **Wider Reach:** Can serve multiple users simultaneously.
      * **Scalability:** Can leverage cloud infrastructure for scaling.
      * **Shared Resources:** Can connect to shared databases or external APIs centrally.
    </Callout>

    <Callout type="warning">
      <Icon icon="exclamation-triangle" iconType="solid" /> **Disadvantages**

      * **Connectivity Dependent:** Requires a stable internet connection.
      * **Complex Authentication:** Needs robust security measures for remote access.
      * **Privacy Considerations:** Data transfer over the network requires careful handling.
      * **Network Latency:** Communication speed is affected by network conditions.
      * **Infrastructure Costs:** Hosting and maintenance expenses.
    </Callout>

    **Primary Communication Methods**:

    * <Icon icon="exchange-alt" iconType="solid" /> HTTP with Server-Sent Events (SSE)
    * <Icon icon="stream" iconType="solid" /> Streamable HTTP (Evolving standard)
    * <Icon icon="plug" iconType="solid" /> WebSockets (Planned/Supported by some)
      **Best suited for**: `Cloudflare agents`, `@modelcontextprotocol/sdk`, `fastmcp`, `mcp-framework`
  </Tab>
</Tabs>

## <Icon icon="boxes" iconType="solid" /> Framework Deep Dive

Explore the core philosophy, features, typical use cases, and code examples for each framework.

### <Icon icon="puzzle-piece" iconType="solid" /> Overview & Philosophy

Understand the main goal and design principles behind each framework.

<Tabs items={['@modelcontextprotocol/sdk', 'Cloudflare agents', 'fastmcp', 'mcp-framework']}>
  <Tab title="@modelcontextprotocol/sdk">
    * **Goal:** Provide the official, foundational TypeScript implementation of the MCP specification.
    * **Philosophy:** Offer low-level primitives (`Server`, `Resource`, `Tool`, `Prompt`) for maximum control and strict spec adherence. Does not impose structure beyond the MCP core.
    * **Nature:** A library/SDK, not a full framework. Forms the base for other frameworks like `mcp-framework`.
  </Tab>

  <Tab title="Cloudflare agents">
    * **Goal:** Enable stateful AI agents on Cloudflare's edge network.
    * **Philosophy:** Leverage Cloudflare infrastructure (Workers, Durable Objects) for persistent, low-latency agent communication. Focuses on the *agent* paradigm integrated with Cloudflare services (AI Gateway, Vectorize). More than just MCP; part of a broader AI ecosystem.
    * **Nature:** A specialized framework tightly coupled with the Cloudflare platform.
  </Tab>

  <Tab title="fastmcp">
    * **Goal:** Simplify production-ready MCP server creation with rich features.
    * **Philosophy:** Prioritize developer experience and robust features like session management, authentication, logging, and error handling out-of-the-box. Aims to be a comprehensive solution for complex MCP applications.
    * **Nature:** A feature-complete, community-driven framework.
  </Tab>

  <Tab title="mcp-framework">
    * **Goal:** Enhance developer experience for building MCP servers using conventions and tooling.
    * **Philosophy:** Built *on top of* `@modelcontextprotocol/sdk`, reducing boilerplate via convention-over-configuration (automatic discovery of tools/resources/prompts in predefined folders) and providing helpful abstractions and CLI tooling (`mcp` command).
    * **Nature:** An opinionated framework focused on DX and rapid development.
  </Tab>
</Tabs>

### <Icon icon="star" iconType="solid" /> Key Features

Highlighting the standout features of each framework.

<Tabs items={['@modelcontextprotocol/sdk', 'Cloudflare agents', 'fastmcp', 'mcp-framework']}>
  <Tab title="@modelcontextprotocol/sdk">
    * **Spec Compliance:** Full, official implementation of the MCP specification.
    * **Core Primitives:** Exports fundamental classes/interfaces (`Server`, `Resource`, `Tool`, `Prompt`).
    * **Transport Flexibility:** Supports `stdio` and `HTTP/SSE`.
    * **Extensibility:** Designed as a base for other frameworks or direct use.
    * **Minimalist:** No built-in session management, auto-discovery, or advanced features; requires manual implementation.
  </Tab>

  <Tab title="Cloudflare agents">
    * **State Management:** Built-in persistence via Cloudflare Durable Objects.
    * **Cloudflare Integration:** Seamless use of Workers, AI Gateway, Vectorize, R2, etc.
    * **Real-time Communication:** Supports `HTTP/SSE`, planned `WebSockets`.
    * **Authentication:** Integrated Cloudflare Access / OAuth.
    * **Developer Tooling:** `wrangler` CLI for development and deployment.
    * **React Hooks:** Utilities for frontend integration.
    * **Agent Lifecycle:** Manages agent persistence and hibernation.
  </Tab>

  <Tab title="fastmcp">
    * **Session Management:** Core feature for stateful client interactions.
    * **Rich Built-ins:** Authentication, image handling, logging, error handling, progress notifications, typed events, CORS.
    * **Transport Support:** `SSE` and `stdio`.
    * **Developer Focus:** Simplified definitions for MCP components.
    * **Testing Utilities:** Includes CLI tools for testing.
    * **Sampling:** Built-in support for sampling parameters.
    * **Automated SSE Pings:** Keep-alive mechanism.
  </Tab>

  <Tab title="mcp-framework">
    * **Convention over Configuration:** Automatic discovery of tools, resources, prompts from predefined directories (`src/tools`, `src/resources`, etc.).
    * **Base Classes:** Simplifies component implementation (`Tool`, `Resource`, `Prompt` base classes).
    * **Multiple Transports:** Supports `stdio`, `SSE`, and experimental `HTTP Stream`.
    * **CLI Tooling:** Powerful `mcp` CLI for project creation (`create`), scaffolding (`add tool`, `add resource`), and development server (`dev`).
    * **Built-in Auth (SSE):** Simple token-based authentication for SSE transport.
    * **Built on Official SDK:** Leverages `@modelcontextprotocol/sdk` underneath.
  </Tab>
</Tabs>

### <Icon icon="code" iconType="solid" /> Code Examples

Illustrative examples of defining a simple "add" tool in each framework.

<Tabs items={['@modelcontextprotocol/sdk', 'Cloudflare agents', 'fastmcp', 'mcp-framework']}>
  <Tab title="@modelcontextprotocol/sdk">
    ```typescript theme={null}
    import { Server } from "@modelcontextprotocol/sdk/server/index.js";
    import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
    import { z } from "zod";

    const AddToolSchema = {
      name: "add",
      description: "Add two numbers together",
      parameters: z.object({
        a: z.number(),
        b: z.number(),
      }),
    };

    const server = new Server({ name: "sdk-example-server", version: "1.0.0" }, {
      capabilities: { tools: {} } 
    });

    server.setToolHandler(AddToolSchema, async (params) => {
      const { a, b } = params;
      const sum = a + b;
      return {
        content: [{ type: "text", text: String(sum) }]
      };
    });

    const transport = new StdioServerTransport();
    await server.connect(transport);
    console.log("SDK Server connected via stdio");
    ```
  </Tab>

  <Tab title="Cloudflare agents">
    ```typescript theme={null}
    import { McpAgent } from "agents/mcp"; 
    import { z } from "zod";

    export class AdditionAgent extends McpAgent {
      server = new McpServer({ name: "cloudflare-agent-adder", version: "1.0.0" });

      async init() {
        this.server.tool(
          "add",
          { 
            a: z.number().describe("First number to add"),
            b: z.number().describe("Second number to add")
          },
          async ({ a, b }) => { 
            const sum = a + b;
            return {
              content: [{ type: "text", text: String(sum) }],
            };
          }
        );
      }
    }
    ```
  </Tab>

  <Tab title="fastmcp">
    ```typescript theme={null}
    import { FastMCP } from "fastmcp";
    import { z } from "zod";

    const server = new FastMCP({
      name: "fastmcp-addition-server",
      version: "1.0.0",
    });

    server.addTool({
      name: "add",
      description: "Add two numbers together",
      parameters: z.object({
        a: z.number().describe("First number to add"),
        b: z.number().describe("Second number to add"),
      }),
      execute: async (args: { a: number; b: number }): Promise<string> => {
        const sum = args.a + args.b;
        return String(sum); 
      },
    });

    server.start({
      transportType: "stdio",
    }).then(() => {
      console.log("FastMCP Server started via stdio");
    }).catch(console.error);
    ```
  </Tab>

  <Tab title="mcp-framework">
    ```typescript theme={null}
    import { Tool } from "mcp-framework";
    import { z } from "zod";

    export class AdditionTool extends Tool {
      name = "add";
      description = "Add two numbers together";

      parameters = z.object({
        a: z.number().describe("First number to add"),
        b: z.number().describe("Second number to add")
      });

      async execute({ a, b }: { a: number; b: number }): Promise<string> {
        const sum = a + b;
        return String(sum); 
      }
    }
    ```
  </Tab>
</Tabs>

### <Icon icon="bullseye" iconType="solid" /> Best For

Summarizing the ideal scenarios for choosing each framework.

<Tabs items={['@modelcontextprotocol/sdk', 'Cloudflare agents', 'fastmcp', 'mcp-framework']}>
  <Tab title="@modelcontextprotocol/sdk">
    **Best For:**

    * **Production Implementations:** Where stability and official support are key.
    * **Strict Compliance:** Projects needing precise adherence to the MCP spec.
    * **Framework Builders:** As a foundation for creating higher-level MCP frameworks.
    * **Maximum Control:** When fine-grained control over server behavior is required.
    * **Learning MCP:** Understanding the core protocol mechanics.
  </Tab>

  <Tab title="Cloudflare agents">
    **Best For:**

    * **Remote Deployment:** Specifically designed for cloud-hosted MCP servers.
    * **Cloudflare Ecosystem Users:** Organizations heavily invested in Cloudflare.
    * **Simplified Deployment/Scaling:** Leveraging Workers and Durable Objects.
    * **OAuth Requirement:** Applications needing built-in OAuth.
    * **Stateful Agents:** When persistence and agent lifecycle are important.
  </Tab>

  <Tab title="fastmcp">
    **Best For:**

    * **Feature-Rich Applications:** Needing built-in auth, sessions, logging, etc.
    * **Streaming / Multi-Step Interactions:** Where session management is beneficial.
    * **Production Focus:** Prioritizing stability and comprehensive features.
    * **Complex Use Cases:** Requiring robust error handling and events.
    * **Community Solution:** Preferring an actively maintained community framework.
  </Tab>

  <Tab title="mcp-framework">
    **Best For:**

    * **Rapid Development:** Quickly scaffolding and building MCP servers.
    * **Convention Preference:** Teams preferring convention-over-configuration.
    * **Focus on Logic:** Abstracting away MCP boilerplate.
    * **CLI Tooling:** Valuing tools for project creation and component generation.
    * **DX Priority:** Seeking an elegant and structured development process.
  </Tab>
</Tabs>

## <Icon icon="check" iconType="solid" /> Making Your Choice: Key Questions

Consider these factors when selecting your framework:

```mermaid theme={null}
graph TD
    %% Define Styles
    classDef decision fill:#e0f2fe,stroke:#a5f3fc,stroke-width:1px,color:#075985,padding:10px 5px;
    classDef start fill:#d1fae5,stroke:#6ee7b7,stroke-width:1px,color:#065f46;
    classDef cloudflare fill:#fef3c7,stroke:#fde68a,stroke-width:1px,color:#92400e,padding:10px 5px,border-radius:8px;
    classDef fastmcp fill:#f3e8ff,stroke:#e9d5ff,stroke-width:1px,color:#6b21a8,padding:10px 5px,border-radius:8px;
    classDef sdk fill:#dbeafe,stroke:#bfdbfe,stroke-width:1px,color:#1e40af,padding:10px 5px,border-radius:8px;
    classDef mcpframework fill:#ccfbf1,stroke:#99f6e4,stroke-width:1px,color:#115e59,padding:10px 5px,border-radius:8px;

    %% Nodes
    A(fa:fa-play Start Choosing) --> B{fa:fa-map-signs Deployment?<br/>Local or Remote?};
    B -- Remote --> C{fa:fa-cloud Using Cloudflare?};
    B -- Local --> D{fa:fa-history Stateful Sessions Needed?};

    C -- Yes --> E(fa:fa-cloudflare **Cloudflare agents**<br/><i>Ideal for CF integration,<br/>stateful, remote</i>);
    C -- No --> D;

    D -- Yes --> F(fa:fa-sync **fastmcp**<br/><i>Strong session management,<br/>feature-rich</i>);
    D -- No --> G{fa:fa-sliders-h Prioritize Control<br/>or DX/Convention?};

    G -- Max Control /<br/>Core Spec --> H(fa:fa-cogs **@modelcontextprotocol/sdk**<br/><i>Official SDK, foundational,<br/>max flexibility</i>);
    G -- DX / Conventions /<br/>CLI --> I(fa:fa-laptop-code **mcp-framework**<br/><i>Focus on Developer Experience,<br/>conventions, CLI</i>);

    %% Apply Styles
    class A start;
    class B,C,D,G decision;
    class E cloudflare;
    class F fastmcp;
    class H sdk;
    class I mcpframework;

    linkStyle default stroke:#9ca3af,stroke-width:2px;
```

<Callout type="info">
  <Icon icon="info-circle" iconType="solid" /> Remember, all these frameworks facilitate building MCP-compliant servers using TypeScript. The best choice depends on your specific project requirements, existing infrastructure, and team preferences. This flowchart provides a starting point; review the detailed features and documentation for your top candidates.
</Callout>

## <Icon icon="link" iconType="solid" /> Further Resources

Official documentation and repositories for each framework.

<Cards>
  <Card title="@modelcontextprotocol/sdk" href="https://github.com/modelcontextprotocol/typescript-sdk">
    <Icon icon="github" iconType="brands" /> Official GitHub Repository & Docs
  </Card>

  <Card title="Cloudflare agents" href="https://github.com/cloudflare/agents">
    <Icon icon="github" iconType="brands" /> Cloudflare agents GitHub Repository & Docs
  </Card>

  <Card title="fastmcp" href="https://github.com/punkpeye/fastmcp">
    <Icon icon="github" iconType="brands" /> fastmcp GitHub Repository & Docs
  </Card>

  <Card title="mcp-framework" href="https://github.com/QuantGeekDev/mcp-framework">
    <Icon icon="github" iconType="brands" /> mcp-framework GitHub Repository & Docs
  </Card>
</Cards>
