The Notion MCP Server provides an implementation of the Model Context Protocol (MCP) for the Notion API, allowing AI assistants to interact with your Notion workspace through natural language commands. This integration lets you search, create content, and manipulate your Notion data seamlessly.
Go to Notion Integrations and create a new internal integration or select an existing one.
For security reasons, consider limiting the capabilities of your integration. You can create a read-only integration by selecting only "Read content" access in the "Configuration" tab.
You need to connect your Notion pages and databases to your integration:
Alternatively, you can grant access individually by:
For Cursor & Claude:
Add the following to your .cursor/mcp.json
or claude_desktop_config.json
(MacOS: ~/Library/Application\ Support/Claude/claude_desktop_config.json
):
{
"mcpServers": {
"notionApi": {
"command": "npx",
"args": ["-y", "@notionhq/notion-mcp-server"],
"env": {
"OPENAPI_MCP_HEADERS": "{\"Authorization\": \"Bearer ntn_****\", \"Notion-Version\": \"2022-06-28\" }"
}
}
}
}
For Zed:
Add the following to your settings.json
:
{
"context_servers": {
"some-context-server": {
"command": {
"path": "npx",
"args": ["-y", "@notionhq/notion-mcp-server"],
"env": {
"OPENAPI_MCP_HEADERS": "{\"Authorization\": \"Bearer ntn_****\", \"Notion-Version\": \"2022-06-28\" }"
}
},
"settings": {}
}
}
}
Option 1: Using the official Docker Hub image:
Add the following to your .cursor/mcp.json
or claude_desktop_config.json
:
{
"mcpServers": {
"notionApi": {
"command": "docker",
"args": [
"run",
"--rm",
"-i",
"-e", "OPENAPI_MCP_HEADERS",
"mcp/notion"
],
"env": {
"OPENAPI_MCP_HEADERS": "{\"Authorization\":\"Bearer ntn_****\",\"Notion-Version\":\"2022-06-28\"}"
}
}
}
}
Option 2: Building the Docker image locally:
First, build the Docker image:
docker-compose build
Then, add the following to your configuration:
{
"mcpServers": {
"notionApi": {
"command": "docker",
"args": [
"run",
"--rm",
"-i",
"-e",
"OPENAPI_MCP_HEADERS={\"Authorization\": \"Bearer ntn_****\", \"Notion-Version\": \"2022-06-28\"}",
"notion-mcp-server"
]
}
}
}
Important: In all configurations, replace ntn_****
with your integration secret from the integration configuration tab.
You can also install Notion API Server for Claude Desktop automatically using Smithery:
npx -y @smithery/cli install @makenotion/notion-mcp-server --client claude
Here are some examples of how to use the Notion MCP Server with natural language commands:
Using the instruction:
Comment "Hello MCP" on page "Getting started"
The AI will correctly plan two API calls, v1/search
and v1/comments
, to accomplish this task.
With the instruction:
Add a page titled "Notion MCP" to page "Development"
The system will create a new page named "Notion MCP" under the parent page "Development".
You can also reference content by ID directly:
Get the content of page 1a6b35e6e67f802fa7e1d27686f017f2
This will retrieve the content from the specified page ID.
To add this MCP server to Claude Code, run this command in your terminal:
claude mcp add-json "notionApi" '{"command":"npx","args":["-y","@notionhq/notion-mcp-server"],"env":{"OPENAPI_MCP_HEADERS":"{\"Authorization\": \"Bearer ntn_****\", \"Notion-Version\": \"2022-06-28\" }"}}'
See the official Claude Code MCP documentation for more details.
There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json
file so that it is available in all of your projects.
If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json
file.
To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".
When you click that button the ~/.cursor/mcp.json
file will be opened and you can add your server like this:
{
"mcpServers": {
"notionApi": {
"command": "npx",
"args": [
"-y",
"@notionhq/notion-mcp-server"
],
"env": {
"OPENAPI_MCP_HEADERS": "{\"Authorization\": \"Bearer ntn_****\", \"Notion-Version\": \"2022-06-28\" }"
}
}
}
}
To add an MCP server to a project you can create a new .cursor/mcp.json
file or add it to the existing one. This will look exactly the same as the global MCP server example above.
Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.
The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.
You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.
To add this MCP server to Claude Desktop:
1. Find your configuration file:
~/Library/Application Support/Claude/claude_desktop_config.json
%APPDATA%\Claude\claude_desktop_config.json
~/.config/Claude/claude_desktop_config.json
2. Add this to your configuration file:
{
"mcpServers": {
"notionApi": {
"command": "npx",
"args": [
"-y",
"@notionhq/notion-mcp-server"
],
"env": {
"OPENAPI_MCP_HEADERS": "{\"Authorization\": \"Bearer ntn_****\", \"Notion-Version\": \"2022-06-28\" }"
}
}
}
}
3. Restart Claude Desktop for the changes to take effect