> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mcp-b.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# @mcp-b/webmcp-ts-sdk overview

> When to use BrowserMcpServer directly, why the browser-adapted SDK exists, and where it fits between the polyfill and application runtime.

`@mcp-b/webmcp-ts-sdk` exposes `BrowserMcpServer`, the browser-adapted SDK layer that keeps the MCP transport model working even when tools register after the connection is already open.

## When to use this package

* You need direct control over the server instance instead of the automatic `@mcp-b/global` setup.
* You are building a custom integration that needs to wrap or subclass the browser server behavior.
* You need the SDK layer without the top-level global initializer.

## When not to use this package

* You are building a typical web application. Start with [`@mcp-b/global`](/packages/global/overview).
* You only need the strict WebMCP surface. Use [`@mcp-b/webmcp-polyfill`](/packages/webmcp-polyfill/overview).

## Where it sits in the package graph

This package sits between the strict runtime and the app-facing entry point. `@mcp-b/global` uses it to replace `document.modelContext` with a `BrowserMcpServer`.

## First step

Create a `BrowserMcpServer`, connect a transport, then register tools as your page state changes. The [reference page](/packages/webmcp-ts-sdk/reference) covers the server methods, backfill behavior, and transport lifecycle.

## Related pages

<CardGroup cols={2}>
  <Card title="Reference" icon="book-open" href="/packages/webmcp-ts-sdk/reference">
    BrowserMcpServer APIs, dynamic registration behavior, and backfill helpers.
  </Card>

  <Card title="Runtime layering" icon="bars-staggered" href="/explanation/architecture/runtime-layering">
    See how this layer fits between the polyfill and @mcp-b/global.
  </Card>

  <Card title="WebMCP vs MCP" icon="arrows-left-right" href="/explanation/webmcp-vs-mcp">
    Why browser runtimes need a different registration model.
  </Card>

  <Card title="Transports overview" icon="network-wired" href="/packages/transports/overview">
    Pick the transport that connects your server.
  </Card>
</CardGroup>
