MCP Architecture — Just Enough to Start
Table of Contents + −
In the previous chapter, we learned what MCP is and why we need it.
We also saw a simple idea:
MCP gives AI applications a standard way to communicate with external capabilities.
Before we start writing code, there is one thing we need to understand.
Who actually talks to whom?
When we say:
what exactly does that mean?
There are a few different parts involved.
Don’t worry — we are not going deep into technical details yet.
Our goal in this chapter is very simple:
Understand the basic MCP picture so that we know what we are going to build.
🧭 The Main Parts of MCP
There are four important things we should know initially:
- AI Model
- MCP Host
- MCP Client
- MCP Server
Let’s understand them one by one.
🧠 1. AI Model
Let’s start with the easiest one.
The AI model is the part that understands what the user is asking.
For example, you tell the AI:
“Calculate 125 × 48.”
The AI understands that you want a calculation.
The AI model is responsible for things like:
- Understanding your request
- Deciding what information it needs
- Deciding whether it needs a tool
- Generating the final response
But there is an important point:
The AI model does not automatically have access to every external system.
For example, just because the AI understands:
“Get today’s weather.”
doesn’t mean it automatically has access to a weather service.
Something needs to provide that capability.
That’s where MCP comes into the picture.
🏠 2. MCP Host
The MCP Host is the AI application that the user interacts with.
For example, imagine an application like:
That overall AI application is the MCP Host.
The Host is responsible for managing the AI experience and MCP connections.
You can think of it as the main application.
For example:
We will understand the exact responsibilities of the Host later.
For now, remember:
MCP Host = the AI application that uses MCP.
🔗 3. MCP Client
Now things get a little more interesting.
The MCP Host uses an MCP Client to communicate with an MCP server.
So we can think of it like this:
The MCP Client is the part that understands how to communicate using MCP.
For example, when the AI application wants to know:
“What capabilities does this MCP server provide?”
the MCP Client communicates with the server and asks for that information.
Later, when the AI wants to use one of those capabilities, the MCP Client sends the request to the MCP Server.
So a simple way to remember it is:
MCP Client = the part that connects to and communicates with an MCP Server.
🖥️ 4. MCP Server
Now let’s look at the other side.
An MCP Server provides capabilities that an AI application can use.
For example, imagine we create a calculator MCP server.
It could provide:
Another MCP server could provide file-related capabilities:
Another could provide information from some other system.
So:
MCP Server = a program that exposes capabilities through MCP.
🔌 How Do They Connect?
Now let’s put everything together.
We have:
AI ModelMCP HostMCP ClientMCP ServerThe basic relationship looks like this:
That’s the basic MCP architecture.
Don’t worry about every arrow yet.
We will understand each part as we build our project.
🧮 A Simple Example
Let’s use our calculator example again.
You tell the AI:
“What is 25 × 40?”
The flow could look like this:
- You ask: “What is 25 × 40?”
- The AI Model understands that this needs calculation.
- The MCP Client sends the request using MCP.
- The Calculator MCP Server calls the calculator capability.
- The calculator performs
25 × 40. - The result is
1000.
Then the result comes back:
1000and the AI can respond to you.
✉️ Let’s Make the Flow Even Simpler
Think of the MCP Client as a messenger.
The AI application says:
“I need to use the calculator.”
The MCP Client communicates with the MCP Server.
The MCP Server has the calculator capability.
So:
The MCP Client is not the calculator.
The MCP Server is not the AI.
They have different jobs.
❓ Why Can’t the AI Talk Directly to the MCP Server?
You might now ask:
“Why do we need an MCP Client? Why can’t the AI model directly talk to the MCP Server?”
This is a good question.
The AI model itself is primarily responsible for understanding and generating language.
The MCP Client is responsible for handling MCP communication.
So we separate the responsibilities.
This separation makes the architecture cleaner.
The AI doesn’t need to know the internal details of every external system.
🌐 One Host Can Have Multiple MCP Servers
This is one of the most useful things to understand.
An AI application doesn’t have to connect to only one MCP server.
It can connect to multiple MCP servers.
For example:
Now our AI application can potentially use capabilities from all three.
For example:
“Calculate 25 × 40.”
It can use the calculator server.
Or:
“Read this file.”
It can use the file server.
Or:
“What’s the weather today?”
It can use the weather server.
The important point is that these capabilities can be provided by different MCP servers.
🌉 MCP Server Is Not Necessarily the External System
This is another important distinction.
Suppose we have:
The calculator itself doesn’t have to understand MCP.
The MCP Server can act as the bridge.
For example:
The MCP Server understands MCP.
It can then communicate with the actual external system using whatever mechanism that system requires.
We don’t need to worry about those details yet.
🗺️ The Complete Basic Picture
Let’s put everything together one more time.
For now, this is all you need to understand.
We will explain Tools, Resources, Prompts, and the communication between the Client and Server later.
🔄 Simple Request Flow
Let’s look at one complete request.
Suppose you ask:
“Add 10 and 20.”
The simplified flow is:
👤 Step 1 — User asks the AI
"Add 10 and 20."🧠 Step 2 — AI Model understands the request
The AI realizes:
“I need a calculation.”
The Host already knows which MCP servers are connected.
Each connected MCP server can tell the Host what capabilities it provides.
For example, a calculator MCP server may provide an add capability.
So the Host can choose the MCP Client that is connected to the calculator MCP server.
🧭 Step 3 — Host chooses the right MCP Client
The Host sees:
- The user needs addition
- The calculator MCP server has an
addcapability - The MCP Client connected to that server should be used
🔗 Step 4 — MCP Client communicates with the MCP Server
The MCP Client sends the request to the calculator MCP server.
⚙️ Step 5 — MCP Server performs the operation
10 + 20Result:
30↩️ Step 6 — Result comes back
The result comes back from the MCP Server to the MCP Client, then back to the Host.
💬 Step 7 — AI responds
"10 + 20 is 30."🖼️ Remember This Picture
For now, remember only this:
And remember what each part means:
| Part | Simple meaning |
|---|---|
| AI Model | Understands the user’s request |
| MCP Host | The AI application |
| MCP Client | Communicates with MCP servers |
| MCP Server | Provides capabilities to the client |
That’s enough.
🚀 Now Let’s Build It
We now understand the basic picture.
We know:
- Why MCP exists
- What an MCP Host is
- What an MCP Client is
- What an MCP Server is
- Where the AI model fits
- How a simple request flows through the system
We don’t need to learn anything more before starting.
Let’s write some code. 🚀
In the next chapter, we will create our project and build our first MCP server.
It will be very small.
We won’t start with a complicated application.
We’ll start with the simplest possible MCP server and then keep improving it as we learn.