home / mcp / rednote mcp server

RedNote MCP Server

Provides a MCP server to access Xiaohongshu notes with authentication, keyword search, and URL-based retrieval.

Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "ifuryst-rednote-mcp": {
      "command": "rednote-mcp",
      "args": [
        "--stdio"
      ]
    }
  }
}

RedNote MCP provides a dedicated MCP server to access Xiaohongshu notes with built-in authentication, keyword search, and URL-based retrieval. It lets you run the server locally or via a remote MCP client, enabling seamless integration into your workflows and tools that support the MCP protocol.

How to use

You run the MCP server either as a local stdio process or through a command-line interface, then connect to it from your MCP client. Start by logging in so the server can access your notes securely, then configure your client to communicate with the RedNote MCP server.

How to install

Prerequisites you need before installing:

  • Node.js 16 or later
  • npm 7 or later
  • Playwright environment for login flow

Option 1 — Global installation and login initialization:

# Globally install the MCP server package
npm install -g rednote-mcp

# Initialize login; this saves cookies to your home directory
rednote-mcp init

Option 2 — Install from source and run in development mode:

# Clone the project
git clone https://github.com/ifuryst/rednote-mcp.git
cd rednote-mcp

# Install dependencies
npm install

# Optional: install globally for easier CLI usage
npm install -g .

# Or run directly in development mode, including initialization
npm run dev -- init

Additional setup and tips

After you complete login, cookies are stored in ~/.mcp/rednote/cookies.json. Keep this file secure and do not share it. If cookies expire, repeat the login flow to refresh them.

Configuration for MCP clients

Configure your MCP client to connect to RedNote MCP in stdio mode. You can use either a direct command or npx to invoke the server with the required stdio flag.

{
  "mcpServers": {
    "RedNote MCP": {
      "command": "rednote-mcp",
      "args": [
        "--stdio"
      ]
    }
  }
}

Security considerations

The login process stores session cookies locally. Treat the cookies file as sensitive data and restrict access to your machine. Regularly refresh cookies to avoid expiration.

Troubleshooting and notes

If you encounter issues during login, ensure Playwright is installed and your browser can launch. Verify the cookies file exists at ~/.mcp/rednote/cookies.json after a successful login.

Development and testing notes

Developers can test and debug MCP behavior using the built-in tools. Run tests with the standard test script and use the inspector to validate request/response flows when needed.

Available tools

Authentication management

Handles user authentication with persistent cookies to enable secure access to notes.

Keyword search notes

Supports searching notes by keywords to quickly locate relevant content.

CLI initialization tool

Provides a command to initialize login and set up the environment for MCP usage.

URL-based note access

Allows accessing note content via a direct URL, enabling seamless sharing and retrieval.