Get the FREE Ultimate OpenClaw Setup Guide →

mcp -notion

A Model Context Protocol server wrapping the official Notion SDK

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio ramidecodes-mcp-server-notion npx @ramidecodes/mcp-server-notion@latest -y --api-key=your-notion-integration-key \
  --env NOTION_API_KEY="your-notion-integration-key"

How to use

This MCP server exposes the official Notion SDK so AI models can interact with Notion workspaces through the MCP protocol. It provides tools to search Notion content, query and retrieve databases, manage pages and blocks, list users, handle comments, and generate link previews. After starting the server with your API key, you can configure your AI assistant (Claude Desktop, Cursor AI, or Claude.ai) to communicate with Notion via MCP using the Notion entry. The server handles authentication with the Notion API and exposes a cohesive set of operations that you can invoke from your AI agent to read and modify Notion data as permitted by your integration.

How to install

Prerequisites:

  • Node.js and npm installed on your system
  • A Notion integration key with access to the pages/databases you want to work with

Installation steps:

  1. Ensure Node.js is installed:

  2. Install or use npx to run the MCP server without a global install:

    Run via command line:

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

  3. If you prefer using an environment file, create a .env file with:

    NOTION_API_KEY=your-notion-integration-key

    Then start the server (npx will read the key if using the --api-key flag; env usage is demonstrated in the JSON config):

    npx @ramidecodes/mcp-server-notion@latest -y

  4. Then configure your AI assistant to point to the MCP server using the provided configuration example.

Note: You can also pass the API key directly in the command as --api-key=your-notion-integration-key. If you use environment variables, ensure they are loaded before starting the server.

Additional notes

Tips and considerations:

  • If you encounter authentication or permission issues, double-check that the Notion integration has access to the specific pages/databases and that you’ve invited the integration correctly.
  • Common issues include not sharing the target Notion resources with the integration or using an integration with insufficient capabilities; update the integration settings if needed.
  • You can supply the API key either via the --api-key flag or by setting NOTION_API_KEY in a .env file and using env-path handling if supported by your MCP setup.
  • The server exposes tools for Search, Databases, Pages, Blocks, Users, Comments, and Link Previews; consult the Tools Documentation for detailed usage per tool.
  • If you run into issues with npx on Windows or macOS/Linux, consider using the full path to npx or running the command in a shell that correctly resolves npx.

Related MCP Servers

Sponsor this space

Reach thousands of developers