Skip to content

clarity-mcp-server

MCP Server for Microsoft Clarity based on data export API

build.protocol_tooling.mcp#clarity#behavior-analytics-tools#heatmaps#session-recordings#insights#analytics#mcp#model-context-protocol#ai#agents

Install clarity-mcp-server in your MCP client

clarity-mcp-server is a Model Context Protocol server. Add it to your MCP client config once, restart, and the server's tools become available to your AI assistant. The same JSON snippet below works across all four major clients — only the config file path differs.

  1. Locate your client's MCP config file.
    • Cursor: ~/.cursor/mcp.json
    • Claude Desktop (macOS): ~/Library/Application Support/Claude/claude_desktop_config.json
    • Claude Desktop (Windows): %APPDATA%\Claude\claude_desktop_config.json
    • VS Code: Settings → Extensions → MCP
    • Windsurf: Settings → MCP Servers
  2. Add clarity-mcp-server to the mcpServers map — paste the snippet below into your config file. If you already have other MCP servers, merge the entry into the existing mcpServers object.
  3. Restart your client so it picks up the new server.
  4. Verify — ask the assistant to list available tools; clarity-mcp-server's tools should appear.
{
  "mcpServers": {
    "clarity-mcp-server": {
      "command": "npx",
      "args": [
        "-y",
        "@microsoft/clarity-mcp-server"
      ]
    }
  }
}

Install clarity-mcp-server in Cursor

Open ~/.cursor/mcp.json in your editor, paste the snippet above into mcpServers, save, and restart Cursor. clarity-mcp-server will show up in the assistant's tool list on next launch.

Install clarity-mcp-server in Claude Desktop (macOS)

Open ~/Library/Application Support/Claude/claude_desktop_config.json in your editor, paste the snippet above into mcpServers, save, and restart Claude Desktop (macOS). clarity-mcp-server will show up in the assistant's tool list on next launch.

Install clarity-mcp-server in Claude Desktop (Windows)

Open %APPDATA%\Claude\claude_desktop_config.json in your editor, paste the snippet above into mcpServers, save, and restart Claude Desktop (Windows). clarity-mcp-server will show up in the assistant's tool list on next launch.

Install clarity-mcp-server in VS Code

Open Settings → Extensions → MCP in your editor, paste the snippet above into mcpServers, save, and restart VS Code. clarity-mcp-server will show up in the assistant's tool list on next launch.

npm package: @microsoft/clarity-mcp-server

Transport

clarity-mcp-server supports the following MCP transports. Most AI clients use stdio by default for locally-installed servers.

stdio

From the clarity-mcp-server README

# Microsoft Clarity MCP Server This is a Model Context Protocol (MCP) server for the Microsoft Clarity. It allows you to access your session recordings, project analytics, and documentation from Clarity using Claude for Desktop or other MCP-compatible clients. ## Key Features - **Analytics Data Access**: Query your Microsoft Clarity analytics data including traffic metrics, user behavior insights, and performance statistics - **Session Recording Retrieval**: Access and analyze session recordings to understand user interactions and identify optimization opportunities - **Natural Language Querying**: Ask questions in plain English to get insights from your data - no need to learn complex query syntax or API endpoints - **Flexible Data Filtering**: Filter results by various dimen

Other Model Context Protocol servers in the same space as clarity-mcp-server. Each one adds different capabilities to your AI assistant — pick based on the data sources or workflows you need.

Browse the full MCP server directory or use Stork's one-line install to let your agent pick the right server automatically.