# @modelcontextprotocol/server

> Model Context Protocol implementation for TypeScript - Server package

Latest version **2.0.0** (published 2026-07-27) · MIT license · 0 weekly downloads

## Install

```sh
npm install @modelcontextprotocol/server
pnpm add @modelcontextprotocol/server
yarn add @modelcontextprotocol/server
bun add @modelcontextprotocol/server
```

## Health

**Score 60/100 (C)** — status: active.

Positive: no vulnerabilities; recently updated; high maintenance score; popular repo.

Warnings: low downloads; no types; no esm support.

## Facts

| | |
|---|---|
| Version | 2.0.0 |
| Published | 2026-07-27 |
| First published | 2026-04-01 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 13443 |
| Author | Anthropic, PBC |
| Maintainers | jspahrsummers, pcarleton, fweinberger, thedsp, ochafik-ant, cliffhall |
| Keywords | modelcontextprotocol, mcp, server |

## Links

- npm: https://www.npmjs.com/package/@modelcontextprotocol/server
- Repository: https://github.com/modelcontextprotocol/typescript-sdk
- Homepage: https://modelcontextprotocol.io
- Issues: https://github.com/modelcontextprotocol/typescript-sdk/issues
- npm.io page: https://npm.io/package/@modelcontextprotocol/server

## Recent versions

- 2.0.0 (latest) — 2026-07-27
- 2.0.0-beta.5 — 2026-07-21
- 2.0.0-beta.4 — 2026-07-13
- 2.0.0-beta.3 — 2026-07-09
- 2.0.0-beta.2 — 2026-07-02
- 2.0.0-beta.1 — 2026-06-30
- 2.0.0-alpha.4 — 2026-06-30
- 2.0.0-alpha.3 — 2026-06-25
- 2.0.0-alpha.2 — 2026-04-01
- 2.0.0-alpha.1 — 2026-04-01

## README

# `@modelcontextprotocol/server`

The MCP (Model Context Protocol) TypeScript server SDK. Build MCP servers that expose tools, resources, and prompts.

<!-- prettier-ignore -->
> [!WARNING]
> **v2 is the stable release line**, implementing the [2026-07-28 MCP spec](https://modelcontextprotocol.io/specification/2026-07-28). Migrating from v1? Start with the [migration guide](https://ts.sdk.modelcontextprotocol.io/v2/migration/).

<!-- prettier-ignore -->
> [!NOTE]
> This is **v2** of the MCP TypeScript SDK. It replaces the monolithic `@modelcontextprotocol/sdk` package from v1. See the **[migration guide](https://github.com/modelcontextprotocol/typescript-sdk/blob/main/docs/migration/upgrade-to-v2.md)** if you're coming from v1.

## Install

```bash
npm install @modelcontextprotocol/server
```

TypeScript ≥6.0 no longer auto-includes `@types/*` — add `"types": ["node"]` to your `tsconfig.json` `compilerOptions` (the published `.d.mts` references `Buffer`).

Optional framework adapters: [`@modelcontextprotocol/express`](https://www.npmjs.com/package/@modelcontextprotocol/express), [`@modelcontextprotocol/fastify`](https://www.npmjs.com/package/@modelcontextprotocol/fastify), [`@modelcontextprotocol/hono`](https://www.npmjs.com/package/@modelcontextprotocol/hono),
[`@modelcontextprotocol/node`](https://www.npmjs.com/package/@modelcontextprotocol/node).

## Documentation

- **[Repository README](https://github.com/modelcontextprotocol/typescript-sdk#readme)** — overview, package layout, examples
- **[Server guide](https://ts.sdk.modelcontextprotocol.io/v2/servers/tools)** — tools, resources, prompts, and the rest of the server surface
- **[Serving guide](https://ts.sdk.modelcontextprotocol.io/v2/serving/http)** — stdio, HTTP, the framework adapters, sessions, and authorization
- **[API reference](https://ts.sdk.modelcontextprotocol.io/v2/)**
- **[MCP specification](https://modelcontextprotocol.io)**

---
_Source: https://npm.io/package/@modelcontextprotocol/server · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
