# Yandex Metrika (MCP server)

> Yandex Metrika is an MCP server that adds data and analytics tools to AI assistants such as Claude Desktop, Claude Code and Cursor. Read-only Yandex Metrika (Яндекс Метрика) analytics: verifiable reports, comparisons and exports. It has 130 GitHub stars, is released under the MIT license and runs locally with npx -y @dev-crabs/yandex-metrika-mcp.

Read-only MCP server for Yandex Metrika (Yandex Metrica, Яндекс Метрика). Connect it to Claude, Cursor, VS Code, Codex or any MCP client and ask about traffic, sources, landing pages and goals. Every answer comes with exact dates, the counter time zone, sampling status, filters and provenance, so the numbers can be checked.

## Key facts

| Fact | Value |
|---|---|
| Repository | https://github.com/DevCrabs-Inc/yandex-metrika-mcp |
| GitHub stars | 130 |
| License | MIT |
| Language | TypeScript |
| Transport | stdio |
| Packages | npm: @dev-crabs/yandex-metrika-mcp |
| Remote URL | none |
| Needs API key | no |
| Official | no |
| Works with | Claude Desktop, Claude Code, Cursor, VS Code |
| Category | Data & analytics |
| Latest release | v1.0.0 (Nov 9, 2026) |
| Last commit | Nov 10, 2026 |
| MCP registry name | io.github.DevCrabs-Inc/yandex-metrika-mcp |

## Install

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "yandex-metrika": {
      "command": "npx",
      "args": [
        "-y",
        "@dev-crabs/yandex-metrika-mcp"
      ],
      "env": {
        "YANDEX_METRIKA_TOKEN": "your-value"
      }
    }
  }
}
```

Settings > Developer > Edit Config. macOS: ~/Library/Application Support/Claude/, Windows: %APPDATA%\Claude\. Restart Claude Desktop afterwards.

### Claude Code

```sh
claude mcp add --env YANDEX_METRIKA_TOKEN=your-value --transport stdio yandex-metrika -- npx -y @dev-crabs/yandex-metrika-mcp
```

### Cursor (.cursor/mcp.json)

```json
{
  "mcpServers": {
    "yandex-metrika": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@dev-crabs/yandex-metrika-mcp"
      ],
      "env": {
        "YANDEX_METRIKA_TOKEN": "your-value"
      }
    }
  }
}
```

Project file; use ~/.cursor/mcp.json to enable it in every project.

### VS Code (.vscode/mcp.json)

```json
{
  "inputs": [
    {
      "type": "promptString",
      "id": "yandex_metrika_token",
      "description": "YANDEX_METRIKA_TOKEN",
      "password": true
    }
  ],
  "servers": {
    "yandex-metrika": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@dev-crabs/yandex-metrika-mcp"
      ],
      "env": {
        "YANDEX_METRIKA_TOKEN": "${input:yandex_metrika_token}"
      }
    }
  }
}
```

Config formats checked against the official docs on 2026-10-07.

## Environment variables

- `YM_MCP_CLIENT_ID`: Optional: your own Yandex OAuth app client ID (public PKCE client, no secret).
- `YANDEX_METRIKA_TOKEN` (secret): Optional: an existing OAuth token with metrika:read, for headless setups.

## Tools

- `metrika_status`: Connections, exports and the next step. Works before sign-in.
- `metrika_catalog`: Presets, metrics (with aggregation rules), dimensions, period presets.
- `metrika_run_report`: One period: presets or explicit fields, filters, sorting, paging.
- `metrika_compare_periods`: Two periods under identical conditions: absolute, % and p.p. changes.
- `metrika_run_timeseries`: Day, week or month buckets with exact calendar boundaries.

## Similar MCP servers

- [MCP BigQuery Server](https://appsgit.com/mcp-servers/mcp-bigquery-server): A Model Context Protocol (MCP) server that provides secure, read-only access to BigQuery datasets. (148 stars, MIT)
- [Pug](https://appsgit.com/mcp-servers/pug): Query events, funnels, retention and profiles in Pug product analytics, and build dashboards. (111 stars, AGPL-3.0, official)
- [Muxinc MCP Server](https://appsgit.com/mcp-servers/muxinc-mcp-server): The official MCP Server for the Mux API. (182 stars, Apache-2.0, official, needs API key)
- [Spytrend](https://appsgit.com/mcp-servers/spytrend): Analytics, advertising: Facebook/Meta, TikTok, competitor ads. (86 stars, MIT, official)
- [Betterlytics](https://appsgit.com/mcp-servers/betterlytics): Query your Betterlytics web analytics from AI agents: traffic, funnels, journeys, errors, uptime. (193 stars, AGPL-3.0, official, needs API key)
- [Markifact - Ads & Analytics](https://appsgit.com/mcp-servers/markifact-ads-analytics): AI marketing agent for Google Ads, Meta, GA4, TikTok, LinkedIn, Shopify, HubSpot and more. (60 stars, MIT, official)

---

Canonical page: https://appsgit.com/mcp-servers/yandex-metrika
Source: appsgit (https://appsgit.com), the app store for github. Data from the GitHub API, refreshed daily.
Machine access: JSON API https://appsgit.com/api/v1/apps (OpenAPI: https://appsgit.com/openapi.json), MCP server https://mcp.appsgit.com/mcp, full index https://appsgit.com/llms-full.txt.
