Home / Glossary / MCP authentication
Glossary
What is MCP authentication?
MCP authentication is how an MCP client proves who it is to an MCP server before the server lets it use tools and data. For servers reached over HTTP, the Model Context Protocol specification bases this on OAuth 2.1 and access tokens. The specification makes it optional, so an MCP server can run without it.
By the AIBound team · Updated 17 November 2026
Key takeaways
- MCP authentication is how an MCP client proves who it is to an MCP server.
- The MCP specification bases it on OAuth 2.1 for servers reached over HTTP, and it is optional.
- A local MCP server takes its credentials from the environment on the device and does not use the OAuth flow.
Why MCP authentication matters
An MCP server gives an AI agent a way into files, data and systems. If the server does not check who is calling, anything that can reach it can use its tools. Authentication ties each request to a known client and a person who agreed to it.
The specification treats two kinds of server differently. A server reached over HTTP should follow the OAuth flow. A local server that runs on the laptop over standard input and output should take its credentials from the environment. That often means an API key stored on the employee device, which is one more secret to protect.
How MCP authentication works
In OAuth terms, the MCP server is the resource server and the MCP client is the client. A separate authorization server signs the user in and issues tokens.
- 1 The client calls the MCP server with no token, and the server answers with a 401 response that points to its metadata.
- 2 The client reads the metadata to find the authorization server for that MCP server.
- 3 The employee signs in and approves, and the authorization server issues an access token for that one MCP server.
- 4 The client sends the token in the Authorization header on every request, and the server checks the token was issued for it.
MCP authentication vs MCP authorization
Authentication asks who is calling. Authorization asks what that caller may do. The MCP specification covers both in one section, which it names Authorization.
| Question | MCP authentication | MCP authorization |
|---|---|---|
| What does it answer? | Who the client is and who it acts for | What the client may do on the server |
| What carries it? | An access token the server checks on every request | The scopes granted to that token |
| What happens when it fails? | The server answers 401, and the client must get a valid token | The server answers 403, because the token does not allow the action |
Sources
- Model Context Protocol specification: Authorization (2025-11-25) · modelcontextprotocol.io
- Model Context Protocol specification: Authorization (2025-06-18) · modelcontextprotocol.io
Sources checked 17 November 2026
Examples
MCP authentication examples
FAQ
Frequently asked questions
What is MCP authentication?
MCP authentication is how an MCP client proves who it is to an MCP server. For servers reached over HTTP, the MCP specification uses OAuth 2.1. The client gets an access token from an authorization server and sends it with every request. The server checks the token before it runs a tool.
Does MCP require authentication?
No. The MCP specification says authorization is optional. When a server reached over HTTP supports it, the server should follow the OAuth 2.1 flow in the specification. A local server that runs over standard input and output should take its credentials from the environment instead.
Does MCP use OAuth?
Yes, for servers reached over HTTP. The MCP specification bases its flow on OAuth 2.1. The MCP server acts as the resource server, the MCP client acts as the OAuth client, and an authorization server issues the access tokens. Clients must use PKCE, and tokens must never be placed in the URL.
What is the difference between MCP authentication and authorization?
Authentication proves who the client is and who it acts for. Authorization decides what that client may do, through the scopes on its token. The MCP specification covers both in a section named Authorization. A server must only accept tokens issued for it and must not pass them on to other services.