What is Model Context Protocol (MCP)?
Model Context Protocol (MCP) is an open source protocol that enables 2-way connection and standardized communication between AI applications and external services. An open source protocol, or set of instructions, is like a recipe for code that’s freely available to use and contribute to.
MCP provides a simplified and reliable way for AI systems to virtually “plug in” to different data sources and tools. Think of MCP as a USB-C cable that connects devices to accessories and allows for transmission of data.
What's the purpose of MCP?
Before MCP, developers had to create custom application programming interface (API) integrations for specific use cases. This meant they were rewriting the same integrations many times in slightly different ways. Each connection between an AI application and an external service was made to order, which was extremely time consuming.
With MCP, developers can use a single, standardized protocol to connect an AI application to an external service. MCP doesn’t replace APIs—it standardizes communication on top of APIs. This makes it easier to build complex AI workflows with large language models (LLMs) and connect those models to real-world data.
MCP supplements traditional methods like retrieval-augmented generation (RAG) and provides security controls and interfaces organizations need to deploy agentic AI within their existing systems and workflows.
4 key considerations for implementing AI technology
How MCP communication works
MCP is based on the client-host-server model, also known as the client-server model, which includes an:
- MCP client: the AI application or system that requests access to external data or resources.
- MCP host: the infrastructure (virtual machine, container, or serverless function) that manages communication between the client and server.
- MCP server: the component that provides specific tools, resources, and capabilities to the client.
MCP begins with a handshake protocol. This initial greeting—also known as a capability discovery—confirms that the MCP client and the MCP server can talk to each other.
During the handshake protocol, the MCP client and the MCP server swap critical information to ensure they’re compatible. The client shares which capabilities it has and which version of MCP it understands. In return, the server shares which capabilities it supports and which tools and resources it can provide to the client.
Once this initial meet and greet is complete, the working relationship can begin.
Let’s talk about context
If the “M” refers to language models, and “P” refers to a standardized communication protocol, let’s talk about the “C” in MCP: context.
In the realm of MCP, context refers to the relevant, task-specific information a model has access to. A context window refers to the amount of information a model can access as it generates a response.
Before MCP, AI applications had to hold a lot of information in their context window. Some of that information was irrelevant and cluttered up the space in the context window, leading to hallucinations. With MCP, the application can communicate with tools and services more effectively, asking for exactly what it needs rather than holding on to irrelevant information.
With relevant and adequate context, models can remember previous parts of the conversation, provide more accurate results, and make better connections between pieces of information. MCP lets the client store relevant data in its memory to help complete the request. This process is called dynamic discovery.
Dynamic discovery, which happens after the capability discovery stage, lets the client and server collaboratively solve problems for the user. That ability to share and analyze relevant data provides context to the model, allowing AI applications to act flexibly and independently.
Types of MCP servers
MCP servers play a critical role in providing context to the MCP client. Understanding the different types of MCP servers helps you understand which integrations are possible and how to structure your AI workflow.
Local data sources. These servers connect to information stored on your computer, including files, local databases, or applications.
Remote services. These servers connect to external services via the internet, including cloud databases and web-based tools.
Official integrations. Organizations prebuild these servers to offer connections to popular services that come with guaranteed quality and support.
Community servers. Developers build these servers and openly share them within the developer community.
Reference servers. These servers act as templates and learning tools by showing best practices.
MCP and security
MCP servers make tapping into data and information more convenient than ever before. But this begs the question: How can we keep the data on our MCP servers protected?
Permissions and security policies regulate what MCP servers can access and what they’re allowed to do. MCP provides built-in security features like OAuth (to authenticate user access), as well as encrypted connections between the client and server.
However, developers should also implement their own security measures. Best practices include:
- Only providing MCP servers with the minimum access they need to function, also known as the principle of least privilege (PoLP). This cybersecurity concept aims to reduce potential damage from unauthorized users, errors, or attacks.
- Periodically reviewing what each server can access and making sure none of the servers have unnecessary or excessive permissions.
- Understanding (as a user) what you’re granting access to when you authorize an MCP connection.
- Only using MCP servers you trust.
MCP and agentic AI
Agentic AI is a software system that interacts with data and tools in a way that requires minimal human intervention. With an emphasis on goal-oriented behavior, agentic AI can accomplish tasks by creating a list of steps and performing them autonomously.
MCP and agentic AI enable each other to create intelligent AI systems. With MCP, AI systems can interact with the broader digital ecosystem to accomplish tasks for users. Without MCP, agentic AI can think and plan (all the traits of generative AI), but can’t interact with any outside systems.
How Red Hat can help
Red Hat has identified a curated collection of MCP servers that integrate with Red Hat® OpenShift® AI, which is included in our AI suite of products.
AI engineers using Red Hat OpenShift AI can take advantage of these MCP servers to integrate enterprise tools and resources into their AI applications and agentic workflows.
Explore the collection of MCP servers →
Red Hat AI allows AI engineers and data scientists to improve the accuracy, speed, and relevance of model responses. By connecting models to data for efficient model customization, Red Hat AI helps organizations develop and deploy AI applications at scale.
Red Hat AI’s core platform services let organizations build consistent and repeatable processes, simplifying the deployment of AI agents to production environments.
Artificial intelligence (AI)
See how our platforms free customers to run AI workloads and models anywhere.