Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
autoclaw-cc avatar

Setup Xhs Mcp

  • 8 installs
  • 244 repo stars
  • Updated March 5, 2026
  • autoclaw-cc/xiaohongshu-mcp-skills

setup-xhs-mcp is a Claude skill that installs the xiaohongshu-mcp service and configures the MCP connection for clients like Claude Code or Cursor.

About

This skill installs and deploys the xiaohongshu-mcp service and configures the MCP connection for a client such as Claude Code or Cursor. A developer uses it the first time they want Xiaohongshu automation or when MCP tools like check_login_status are unavailable. It detects service status, offers Docker Compose, binary, or source deployment, writes the MCP config, and validates the connection before login.

  • Installs and configures the xiaohongshu-mcp service end to end (Docker, binary, or source)
  • Detects service status, wires the MCP connection into Claude Code or Cursor, and verifies login
  • Covers proxy, headless, and custom-Chromium environment variables

Setup Xhs Mcp by the numbers

  • 8 all-time installs (skills.sh)
  • Ranked #12,339 of 16,546 AI & Agent Building skills by installs in the Skillselion catalog
  • Data as of Aug 5, 2026 (Skillselion catalog sync)
At a glance

setup-xhs-mcp capabilities & compatibility

Free and self-hosted; runs locally at localhost:18060, optional proxy via XHS_PROXY.

Capabilities
mcp setup · service deployment · client configuration
Works with
docker · github
Use cases
devops
Platforms
macOS · Linux · Windows
IDEs
cursor ide
Runs
Runs locally
Pricing
Free
From the docs

What setup-xhs-mcp says it does

安装部署 xiaohongshu-mcp 服务并配置 MCP 连接,引导用户完成从零到可用的全流程。
SKILL.md
claude mcp add xiaohongshu --transport http <地址>
SKILL.md
**提示用户重启当前会话** — MCP 配置变更后需重启客户端才能加载新的 MCP 工具
SKILL.md
npx skills add https://github.com/autoclaw-cc/xiaohongshu-mcp-skills --skill setup-xhs-mcp

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs8
repo stars244
Last updatedMarch 5, 2026
Repositoryautoclaw-cc/xiaohongshu-mcp-skills

What it does

Install the xiaohongshu-mcp service and wire its MCP connection into a client like Claude Code.

Who is it for?

First-time setup or repair of the xiaohongshu-mcp service and its client MCP connection.

Skip if: Publishing or browsing Xiaohongshu content (use post-to-xhs, xhs-explore, or xhs-interact after setup).

When should I use this skill?

First using Xiaohongshu features, deploying the service, or when MCP tools are unavailable.

What you get

The xiaohongshu-mcp service is running and connected, verified via check_login_status.

  • a running xiaohongshu-mcp service at http://localhost:18060/mcp
  • a configured MCP connection in the client

By the numbers

  • 3 deployment methods (Docker, binary, source)
  • 5-step execution flow

Files

SKILL.mdMarkdownGitHub ↗

项目仓库:https://github.com/xpzouying/xiaohongshu-mcp

执行流程

1. 检测服务状态

检查 xiaohongshu-mcp 是否已在运行(注意:MCP 端点只接受 POST,GET 会返回 405,不能用 -f 判断):

curl -so /dev/null http://localhost:18060/mcp && echo "running" || echo "not running"
  • 已运行 → 记录地址 http://localhost:18060/mcp,跳到步骤 3
  • 未运行 → 询问用户:服务是否部署在其他地址/端口?
  • 用户提供地址 → 验证可达后跳到步骤 3
  • 未部署 → 进入步骤 2

2. 部署服务

确认操作系统(macOS / Linux / Windows)和是否已安装 Docker。

方式一:Docker Compose(推荐)

Docker 镜像内置 Chrome 和中文字体,无需额外配置。

# 下载 docker-compose.yml
wget https://raw.githubusercontent.com/xpzouying/xiaohongshu-mcp/main/docker/docker-compose.yml

# 启动服务
docker compose up -d

# 查看日志
docker compose logs -f

镜像源:

  • Docker Hub(默认):xpzouying/xiaohongshu-mcp
  • 阿里云(国内推荐):crpi-hocnvtkomt7w9v8t.cn-beijing.personal.cr.aliyuncs.com/xpzouying/xiaohongshu-mcp

切换方法:编辑 docker-compose.yml,注释默认 image 行,取消注释阿里云 image 行。

数据持久化:

  • ./data — cookies 登录状态
  • ./images — 发布图片时的挂载目录
方式二:下载二进制

从 GitHub Releases 下载:https://github.com/xpzouying/xiaohongshu-mcp/releases/latest

curl -s https://api.github.com/repos/xpzouying/xiaohongshu-mcp/releases/latest | grep browser_download_url

注意:二进制方式需要本机已安装 Chrome 或 Chromium。

方式三:源码编译

不推荐,仅适合 Go 开发者。参考项目仓库 README。

部署完成后用 curl 确认服务已启动,然后进入步骤 3。

3. 检测 MCP 连接配置

检查当前客户端是否已配置 xiaohongshu MCP 连接。

Claude Code:读取 ~/.claude/settings.json 和项目级 .claude/settings.json,查找 mcpServers 中是否有 xiaohongshu 配置。

  • 已配置且地址正确 → 跳到步骤 5
  • 已配置但地址不匹配 → 修正地址
  • 未配置 → 进入步骤 4

4. 配置 MCP 连接

询问用户:

连接地址:如果步骤 1 已确认可达的地址,用该地址作为默认值,否则默认 http://localhost:18060/mcp

使用的客户端

Claude Code

claude mcp add xiaohongshu --transport http <地址>

或写入配置文件:

  • 全局:~/.claude/settings.json
  • 项目级:.claude/settings.json
{
  "mcpServers": {
    "xiaohongshu": {
      "url": "http://localhost:18060/mcp"
    }
  }
}

Cursor.cursor/mcp.json):

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

其他客户端:告知用户 MCP 服务地址,让用户按客户端文档自行配置。

5. 验证与提示

1. 提示用户重启当前会话 — MCP 配置变更后需重启客户端才能加载新的 MCP 工具 2. 重启后调用 check_login_status 验证连接正常 3. 验证成功 → 引导用户使用 /xhs-login 完成扫码登录

环境变量(可选)

  • XHS_PROXY — HTTP/HTTPS/SOCKS5 代理地址
  • ROD_BROWSER_BIN — 自定义 Chromium 路径
  • HEADLESS — 无头模式开关

失败处理

场景处理
Docker 未安装建议安装 Docker 或改用二进制方式
国内拉取镜像慢切换到阿里云镜像源
端口 18060 被占用检查已有进程,或更换端口
Chrome 未安装(二进制方式)引导安装 Chrome 或改用 Docker 方式
配置写入后工具仍不可用提示重启客户端会话
已有配置但地址错误修正地址并重启

Related skills

FAQ

Which deployment methods are supported?

Docker Compose (recommended), downloading a binary, or building from source.

Why must I restart after configuring?

The docs note MCP config changes require restarting the client session before the new MCP tools load.

AI & Agent Buildingagentsautomation

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.