NestDaddy

Yandex Metrica Mcp

io.github.BoxLab-Ltd/yandex-metrica-mcp · v1.0.1

Query Yandex Metrica analytics — reports, trends, metadata and raw log exports — via an AI agent.

Connect Runs on your machine

Terminal
claude mcp add yandex-metrica-mcp -e YANDEX_METRIKA_TOKEN=<YANDEX_METRIKA_TOKEN> -e YANDEX_METRIKA_COUNTER_ID=<YANDEX_METRIKA_COUNTER_ID> -e YANDEX_METRIKA_ENABLE_WRITE=<YANDEX_METRIKA_ENABLE_WRITE> -e YANDEX_METRIKA_LOGS_DIR=<YANDEX_METRIKA_LOGS_DIR> -- npx -y [email protected]
claude_desktop_config.json
{
  "mcpServers": {
    "yandex-metrica-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "[email protected]"
      ],
      "env": {
        "YANDEX_METRIKA_TOKEN": "<YANDEX_METRIKA_TOKEN>",
        "YANDEX_METRIKA_COUNTER_ID": "<YANDEX_METRIKA_COUNTER_ID>",
        "YANDEX_METRIKA_ENABLE_WRITE": "<YANDEX_METRIKA_ENABLE_WRITE>",
        "YANDEX_METRIKA_LOGS_DIR": "<YANDEX_METRIKA_LOGS_DIR>"
      }
    }
  }
}
~/.cursor/mcp.json
{
  "mcpServers": {
    "yandex-metrica-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "[email protected]"
      ],
      "env": {
        "YANDEX_METRIKA_TOKEN": "<YANDEX_METRIKA_TOKEN>",
        "YANDEX_METRIKA_COUNTER_ID": "<YANDEX_METRIKA_COUNTER_ID>",
        "YANDEX_METRIKA_ENABLE_WRITE": "<YANDEX_METRIKA_ENABLE_WRITE>",
        "YANDEX_METRIKA_LOGS_DIR": "<YANDEX_METRIKA_LOGS_DIR>"
      }
    }
  }
}
.vscode/mcp.json
{
  "servers": {
    "yandex-metrica-mcp": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "[email protected]"
      ],
      "env": {
        "YANDEX_METRIKA_TOKEN": "<YANDEX_METRIKA_TOKEN>",
        "YANDEX_METRIKA_COUNTER_ID": "<YANDEX_METRIKA_COUNTER_ID>",
        "YANDEX_METRIKA_ENABLE_WRITE": "<YANDEX_METRIKA_ENABLE_WRITE>",
        "YANDEX_METRIKA_LOGS_DIR": "<YANDEX_METRIKA_LOGS_DIR>"
      }
    }
  }
}

Replace the values in angle brackets with your own. Keys stay on your machine; we never see them.

Tools

This server runs locally, so its tools are listed by your MCP client once it starts.

Environment variables

NameDescription
YANDEX_METRIKA_TOKEN
Optional, secret
Yandex Metrica OAuth token (metrika:read). Optional if you run the `auth` login.
YANDEX_METRIKA_COUNTER_ID
Optional
Default counter id, so tools may omit counterId.
YANDEX_METRIKA_ENABLE_WRITE
Optional
Set to 1 to add the write tools (chart annotations, expense upload). Sign-in then also asks for metrika:write; every change is confirmed.
YANDEX_METRIKA_LOGS_DIR
Optional
Directory for Logs API file exports (logs_download in file mode). Defaults to a folder under the OS temp directory.

Details

Package[email protected] (NPM, stdio)
First published5 Nov 2026
Last updated5 Nov 2026
Registry nameio.github.BoxLab-Ltd/yandex-metrica-mcp

More data and analytics servers See all

Listing data from the official MCP registry. Status and tools from NestDaddy's daily check. Browse all MCP servers.