Notion MCP Server

Notion MCP Server

Mirror of

MCP-Mirror

Developer Tools
Visit Server

README

Notion MCP Server

A Model Context Protocol (MCP) server that exposes the official Notion SDK, allowing AI models to interact with Notion workspaces.

<a href="https://glama.ai/mcp/servers/bjc5iac7gt"> <img width="380" height="200" src="https://glama.ai/mcp/servers/bjc5iac7gt/badge" alt="Notion Server MCP server" /> </a>

Quick Start

1. Set up your Notion integration

  1. Go to https://www.notion.so/my-integrations
  2. Create a new integration
  3. Copy the API key

2. Connect your Notion pages to the integration

For your integration to access Notion content, you need to explicitly share your pages or databases with it:

  1. Navigate to the Notion page or database you want to access through the integration
  2. Click the "Share" button in the top-right corner
  3. In the "Add people, groups, or integrations" field, select your integration from the dropdown list
  4. Click "Invite"
  5. Repeat for each page or database you want to make accessible

Note: An integration only has access to pages and databases that have been explicitly shared with it. Parent pages do not automatically grant access to child pages.

3. Add to your AI assistant

You can add this MCP server to Claude Desktop, Cursor AI, or Claude.ai using either of these configuration formats:

Command Line Format

npx @ramidecodes/mcp-server-notion@latest -y --api-key=your-notion-integration-key

JSON Configuration Format

{
  "name": "Notion",
  "command": {
    "args": [
      "@ramidecodes/mcp-server-notion@latest",
      "-y",
      "--api-key=your-notion-integration-key"
    ],
    "env": {},
    "executable": "npx"
  }
}

Replace your-notion-integration-key with the API key from step 1.

Setup Instructions

  • Claude Desktop: Settings > Advanced > Model Context Protocol
  • Cursor AI: Settings > AI > MCP Servers
  • Claude.ai (Web): Profile > Settings > API & Integrations > Model Context Protocol

Available Tools

The server provides tools for interacting with Notion:

  • Search: Find pages or databases
  • Databases: Query and retrieve database entries
  • Pages: Create, retrieve, and update pages
  • Blocks: Manage content blocks (paragraphs, lists, etc.)
  • Users: List users and get user information
  • Comments: Create and list comments
  • Link Previews: Create link previews for URLs

Alternative Setup Methods

Using Environment Variables

Instead of passing the API key directly, you can use a .env file:

  1. Create a .env file with:
NOTION_API_KEY=your-notion-integration-key
  1. Run the server:
npx @ramidecodes/mcp-server-notion@latest -y

JSON Configuration with Environment Variables (for Claude Desktop)

You can also use environment variables in the JSON configuration format:

{
  "name": "Notion",
  "command": {
    "args": ["@ramidecodes/mcp-server-notion@latest", "-y"],
    "env": {
      "NOTION_API_KEY": "your-notion-integration-key"
    },
    "executable": "npx"
  }
}

Command Line Options

OPTIONS:
  -h, --help              Show help message
  -v, --version           Show version information
  --verbose               Enable verbose logging
  --env-path <path>       Path to .env file
  --api-key <key>         Notion API key
  -y                      Skip confirmation prompts

Troubleshooting

If you encounter "Failed to create client" errors:

  • On Windows, try using cmd /c before the npx command
  • On macOS/Linux, try using the full path to npx
  • Test the command in a terminal before adding it to your AI assistant

Common Issues

  • "No access to resource" errors: Make sure you've shared the specific Notion page or database with your integration (see step 2)
  • Integration not appearing in share menu: Try refreshing the page or restarting your browser
  • Limited capabilities: Check that your integration has the appropriate capabilities enabled in the Notion integration settings

Features

  • Full Notion API support through the official SDK
  • MCP compliant for seamless AI integration
  • Comprehensive tools for all Notion operations
  • Robust error handling with detailed messages
  • Easy configuration with environment variables

For detailed documentation on each tool, see the Tools Documentation.

License

This project is licensed under the Apache License 2.0 - see the LICENSE file for details.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
MCP Package Docs Server

MCP Package Docs Server

Facilitates LLMs to efficiently access and fetch structured documentation for packages in Go, Python, and NPM, enhancing software development with multi-language support and performance optimization.

Featured
Local
TypeScript
Claude Code MCP

Claude Code MCP

An implementation of Claude Code as a Model Context Protocol server that enables using Claude's software engineering capabilities (code generation, editing, reviewing, and file operations) through the standardized MCP interface.

Featured
Local
JavaScript
@kazuph/mcp-taskmanager

@kazuph/mcp-taskmanager

Model Context Protocol server for Task Management. This allows Claude Desktop (or any MCP client) to manage and execute tasks in a queue-based system.

Featured
Local
JavaScript
Linear MCP Server

Linear MCP Server

Enables interaction with Linear's API for managing issues, teams, and projects programmatically through the Model Context Protocol.

Featured
JavaScript
mermaid-mcp-server

mermaid-mcp-server

A Model Context Protocol (MCP) server that converts Mermaid diagrams to PNG images.

Featured
JavaScript
Jira-Context-MCP

Jira-Context-MCP

MCP server to provide Jira Tickets information to AI coding agents like Cursor

Featured
TypeScript
Linear MCP Server

Linear MCP Server

A Model Context Protocol server that integrates with Linear's issue tracking system, allowing LLMs to create, update, search, and comment on Linear issues through natural language interactions.

Featured
JavaScript
Sequential Thinking MCP Server

Sequential Thinking MCP Server

This server facilitates structured problem-solving by breaking down complex issues into sequential steps, supporting revisions, and enabling multiple solution paths through full MCP integration.

Featured
Python