How MCP (Model Context Protocol) Works

Intermediate
8 min read· AI & Machine Learning

The Model Context Protocol (MCP) is an open standard for connecting AI models to external tools and data sources. Before MCP, every integration between an AI app and a system (a database, a file store, an API) was custom and one-off. MCP standardises this: a data or tool provider exposes an MCP server, and any MCP-compatible AI application (the client) can connect to it in a uniform way. Often described as "USB-C for AI," it lets tools and models mix and match instead of building bespoke connectors for every pair.

Think of USB-C replacing a drawer full of chargers

Before USB-C, every device needed its own special cable, and you kept a tangled drawer of incompatible chargers. USB-C standardised the port so one cable works with everything. MCP does this for AI: instead of writing a custom connector for each model-to-tool pairing, a tool exposes one standard MCP interface, and any MCP-aware AI app can plug in. Build the connector once, and it works with every compatible model and application.

Step by Step

1 / 5

Key Concepts

MCP Server

A program exposing a tool or data source through the Model Context Protocol. It advertises tools, resources, and prompts in a standard way so any MCP client can use them without a custom connector.

MCP Client

The AI application (chat app, IDE assistant, agent) that connects to MCP servers, discovers their capabilities, and lets the model use them during a task.

Tools, Resources, Prompts

The three things a server can expose: tools (invokable actions), resources (readable data/context), and prompts (reusable prompt templates) — a common vocabulary for AI integrations.

N×M to N+M

The core value: instead of every AI app building a custom connector to every tool (N times M), each side implements MCP once, so any client works with any server.

Key Facts

  • MCP is an open standard introduced by Anthropic to connect AI models to tools and data through a uniform client-server protocol.
  • It relates to function calling but operates at a higher level — function calling is how one model invokes a tool in one app; MCP standardises the integration so tools are reusable across apps.
  • Because it is a shared standard, an MCP server built for one AI application works with any other MCP-compatible application, growing an ecosystem of reusable connectors.

Real-World Applications

Connecting an assistant to your systems

A company exposes internal systems (a ticketing tool, a database, a document store) via MCP servers, so any MCP-compatible AI assistant can securely read data and take actions across them without bespoke integrations.

A reusable tool ecosystem

A developer builds one MCP server for a service (say, a calendar or a code repository), and it immediately works across every MCP-aware AI app — IDE assistants, chat apps, and agents alike.

Frequently Asked Questions

What is the Model Context Protocol (MCP)?

MCP is an open standard for connecting AI models and applications to external tools and data sources through a uniform interface. Instead of building a custom integration for each pairing of an AI app and a system, a tool or data provider exposes an MCP server, and any MCP-compatible AI application (the client) can connect to it in a standardised way. It is often described as "USB-C for AI" because it replaces many bespoke connectors with one common protocol.

What problem does MCP solve?

It solves the combinatorial explosion of AI integrations. Connecting many AI applications to many tools and data sources traditionally required a custom, brittle connector for every pair — an N times M problem. MCP standardises the interface so each AI app and each tool only needs to implement the protocol once (N plus M), after which any compatible client and server can work together. This makes integrations reusable and far cheaper to maintain.

What does an MCP server expose?

An MCP server exposes three kinds of capabilities in a standard way: tools, which are actions the model can invoke (like running a query or calling an API); resources, which are data or context the model can read (like files or records); and prompts, which are reusable prompt templates. An MCP client connects to the server, discovers these capabilities, and lets the AI model use them during a conversation or task.

How is MCP different from function calling?

Function calling is the mechanism by which a single model, within one application, requests to invoke a tool the app has defined. MCP operates at a higher level: it standardises how tools and data sources are exposed so they can be reused across many different AI applications, not wired up individually in each one. In practice, an MCP client can present the tools from MCP servers to the model, which may then use function calling to invoke them — MCP handles the reusable integration layer, while function calling handles the model-to-tool request.

Related Topics