Serverdex · build · Swift

Build an MCP server in Swift

The official Swift SDK, the exact install command, the API you start from — and the real Swift MCP servers in our index to copy. SDK facts read from the repository on 1 December 2026.
Official SDK
Tier 3
with Apple
Swift servers
93
in our index
Requires
Swift 6.1+ (Xcode 16.3+)
toolchain
Good to know: Tier 3 SDK — it implements the 2025-11-25 spec, one revision behind the current 2026-07-28.

1. Install the Swift SDK

package: swift-sdk (SwiftPM, product "MCP")
.package(url: "https://github.com/modelcontextprotocol/swift-sdk.git", from: "0.12.0")

The official SDK repository: modelcontextprotocol/swift-sdk.

2. The shape of a minimal server

start from this API
import MCP

let server = Server(name: "MyModelServer", version: "1.0.0")
let transport = StdioTransport()
try await server.start(transport: transport)

This is the starting API, not a full program — the complete, always-current walkthrough is the official quickstart. Define your tools, then connect a transport (stdio for local, HTTP for remote). Read on 1 December 2026; confirm the current version in the quickstart.

3. Real Swift MCP servers to learn from

most-starred in our index · open source
  1. ESP32 Agent

    onehumanbeing
    A

    Production-ready

    Lets your AI see and control a real iPhone through an ESP32 board over Bluetooth.

    Registry
    5.2k 9d agoMIT
  2. ShipSwift

    signerlabs
    A

    Production-ready

    40+ production-ready SwiftUI recipes for building full-stack iOS apps via MCP.

    Live868 tokRegistry
    3.3k 6 19d agoMIT
  3. Blitz

    blitzdotdev
    A

    Production-ready

    Give AI agents full control over iOS/macOS development via a native macOS app with 30+ MCP tools.

    Registry
    1.8k 4mo agoApache-2.0
  4. NTSCRT

    finnmckenty
    A

    Production-ready

    VHS, CRT and analog TV looks for images and video: preview, animate and render them.

    Registry
    832 7d agoMIT
  5. Prefire

    BarredEwe
    A

    Production-ready

    Render SwiftUI #Preview as PNG images, so an AI agent sees the views it changes

    Registry
    535 9d agoApache-2.0
  6. Mirroir MCP

    jfarcand
    A

    Production-ready

    Drive a stock iPhone via iPhone Mirroring: no Developer Mode, Xcode or WDA. LLM-free skill replay.

    Registry
    420 6d agoApache-2.0

See all Swift MCP servers, or the best-maintained across every language.

4. Connect it, then get it found

Point a client at your server to try it — the client matrix shows which clients support what. When it works, list it on Serverdex: a free listing is a server page with a link back to us, in front of developers choosing MCP servers. Want it live now without the link? Priority Review ($9, one-time) does that.

Questions people ask

What's the official way to build an MCP server in Swift?
Use the official Swift SDK, swift-sdk (SwiftPM, product "MCP"). Install it (.package(url: "https://github.com/modelcontextprotocol/swift-sdk.git", from: "0.12.0")), construct a server, register your tools, and connect a transport. The full, always-current walkthrough is the official quickstart; the snippet here shows the shape. Read from the SDK's repository on 1 December 2026.
Is the Swift SDK production-ready?
Tier 3 — experimental, partial or specialised; fine to build on, with sharper edges. Tier 3 SDK — it implements the 2025-11-25 spec, one revision behind the current 2026-07-28.
How do I test and connect my Swift server?
Run it over stdio and point a client at it. Serverdex's client matrix shows which clients support what; most developers start with Claude Desktop or an IDE client. Once it answers, list it on Serverdex so others find it.