Xiaohongshu

v1.0.0Search & Data Extractionstable

MCP for xiaohongshu.com

mcpmcp-serverxiaohongshu-mcp
Share:
13,702
Stars
0
Downloads
0
Weekly
0/5

What is Xiaohongshu?

Xiaohongshu is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to mcp for xiaohongshu.com

MCP for xiaohongshu.com

This server falls under the Search & Data Extraction category on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • MCP for xiaohongshu.com

Use Cases

Search and extract content from the Xiaohongshu social media platform.
xpzouying

Maintainer

LicenseMIT
Languagego
Versionv1.0.0
UpdatedMay 22, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

Manual Installation

npx xiaohongshu

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use Xiaohongshu

The Xiaohongshu MCP server (xiaohongshu-mcp) enables AI assistants to interact with Xiaohongshu (Little Red Book, 小红书) — China's lifestyle and social commerce platform — through a local browser-automation proxy that handles authentication and content operations. It exposes tools for searching posts, reading feed details and comments, publishing image and video content, liking and favoriting posts, and accessing user profiles, all through natural language commands. Content creators, marketers, and researchers who work with Xiaohongshu can use it to automate posting, monitor engagement, and extract content insights.

Prerequisites

  • A Xiaohongshu account (xiaohongshu.com) with an active login
  • Go 1.21 or higher (for building from source) or Docker for the container-based setup
  • An MCP-compatible client such as Claude Desktop or Claude Code
  • A stable internet connection for browser automation (the server uses headless Chromium by default)
  • Optional: an HTTP/HTTPS/SOCKS5 proxy if operating from outside China (set via XHS_PROXY)
1

Download the pre-built binary

Download the appropriate binary for your platform from the GitHub Releases page. Both a login tool and the MCP server binary are needed.

# Download from: https://github.com/xpzouying/xiaohongshu-mcp/releases
# Example for macOS ARM:
chmod +x xiaohongshu-login-darwin-arm64
chmod +x xiaohongshu-mcp-darwin-arm64
2

Authenticate with your Xiaohongshu account

Run the login tool first to scan a QR code with your Xiaohongshu mobile app. This saves session cookies that the MCP server will reuse.

./xiaohongshu-login-darwin-arm64
3

Start the MCP server

Launch the MCP server after successful login. By default it runs in headless mode. Use -headless=false for a visible browser window for debugging.

./xiaohongshu-mcp-darwin-arm64
# Or with visible browser:
./xiaohongshu-mcp-darwin-arm64 -headless=false
4

Alternatively, use Docker

For a simpler setup, use the Docker image. The compose file handles the browser environment automatically.

docker pull xpzouying/xiaohongshu-mcp
cd docker && docker compose up -d
5

Configure your MCP client

Add the server to your MCP client configuration using the HTTP transport mode, since the server exposes an HTTP endpoint at localhost:18060.

claude mcp add --transport http xiaohongshu-mcp http://localhost:18060/mcp
6

Verify login status

Ask your AI assistant to check the login status using the check_login_status tool to confirm the session is active before performing other operations.

Xiaohongshu Examples

Client configuration

Add this to your claude_desktop_config.json to connect via HTTP transport. Optionally set XHS_PROXY if you need to route through a proxy.

{
  "mcpServers": {
    "xiaohongshu": {
      "url": "http://localhost:18060/mcp",
      "env": {
        "XHS_PROXY": ""
      }
    }
  }
}

Prompts to try

Use these prompts with Claude after the Xiaohongshu MCP server is running and authenticated.

- "Search Xiaohongshu for posts about 'matcha latte recipes' and show me the top 5 results"
- "Get the details and comments for post ID [id]"
- "Post an image to Xiaohongshu with title 'Spring Vibes' and the image at /Users/me/photos/spring.jpg"
- "Check my current Xiaohongshu login status"
- "Show me the homepage feed recommendations on Xiaohongshu right now"

Troubleshooting Xiaohongshu

Login QR code scan succeeds but the server still reports 'not logged in'

Ensure the login tool and the MCP server binary are from the same release version. The login tool writes cookies to a local file; verify it exists and is readable. If cookies have expired, re-run the login tool to refresh them.

publish_content fails or posts appear without images

Xiaohongshu requires image paths to avoid Chinese characters. Use ASCII-only file paths. Titles must be 20 characters or fewer and post body must not exceed 1,000 characters. Video uploads require additional processing time.

MCP client cannot connect to localhost:18060

Confirm the MCP server process is running (`ps aux | grep xiaohongshu-mcp`). Check that no firewall is blocking port 18060. If using Docker, verify the port is exposed in the compose file and that the container is healthy.

Frequently Asked Questions about Xiaohongshu

What is Xiaohongshu?

Xiaohongshu is a Model Context Protocol (MCP) server that mcp for xiaohongshu.com It connects AI assistants to external tools and data sources through a standardized interface.

How do I install Xiaohongshu?

Follow the installation instructions on the Xiaohongshu GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.

Which AI clients work with Xiaohongshu?

Xiaohongshu works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is Xiaohongshu free to use?

Yes, Xiaohongshu is open source and available under the MIT license. You can use it freely in both personal and commercial projects.

Browse More Search & Data Extraction MCP Servers

Explore all search & data extraction servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "xiaohongshu": { "command": "npx", "args": ["-y", "xiaohongshu"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use Xiaohongshu?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides