Yandex Metrica MCP

yandex-metrica-mcp

Read-only MCP server for Yandex Metrica: reports, period comparison, goals and raw log export with browser login

MCP serverMedium riskRussian stack

boxlab-ltd/yandex-metrica-mcp

Install

/plugin marketplace add BoxLab-Ltd/yandex-metrica-mcp
/plugin install yandex-metrica-mcp@boxlab

After installing, run npx yandex-metrica-mcp auth once.

This is third-party code. Review the repository files before installing.

What it does

The server answers the agent's questions about Yandex Metrica traffic: sources, landing pages, conversions, geography, devices and trends. Tools cover flexible reports, two-period comparison with percentage deltas, dimension drill-down and time series. The agent can read counter settings including goals and segments, and export raw visits or hits via the Logs API to a file without dumping rows into context. Login is one command using OAuth with PKCE, no app registration needed.

Who it is for. For marketers, SEO specialists and analysts who work with Yandex Metrica counters.

Good fit when

  • You need traffic by source for the past week
  • You need to compare goal conversions across two periods
  • You need raw session export for analysis outside Metrica

Not a fit when

  • You need to change goals, filters or counter settings
  • Your Yandex account lacks access to the counter

Example request

Compare organic conversions for the Lead goal this week versus last week

Limitations

Early-stage project with no write access to Metrica. The account needs counter access and the metrika:read scope. The token is cached in ~/.config/yandex-metrica-mcp/token.json for about a year, then login must be repeated. Metrica reports may be sampled, and the server reports that to the model.

How to disable. Uninstall the plugin via /plugin or delete the yandex-metrica block from the MCP config. The cached token lives in ~/.config/yandex-metrica-mcp/token.json and can be deleted by hand.

MCP

Transport
stdio
Authentication
API key
Environment variables
Environment variables
YANDEX_METRIKA_COUNTER_ID
Default counter ID
YANDEX_METRIKA_TOKEN
secret
Static OAuth token with metrika:read for non-interactive use
YANDEX_OAUTH_CLIENT_ID
Your own OAuth app ID instead of the built-in one

Security check

  • Stores a Yandex OAuth token on disk
  • Reads site analytics and raw visit logs

README in short

The README explains setup in three steps: an MCP config with npx, login with the auth command, and asking the agent. Besides the config, it installs as a Claude Code plugin or a .mcpb extension for Claude Desktop. It lists the reporting, metadata and Logs API tools and covers auth options: interactive login, static token and your own OAuth app. Example questions show which tools the agent will call. MIT licensed.

FAQ

Do I need to register a Yandex OAuth app?

No, the server uses a built-in public PKCE client. You can plug in your own app via YANDEX_OAUTH_CLIENT_ID.

How do I log in from Claude Desktop without a terminal?

Ask the agent to call the login tool: it opens the browser or returns a link and accepts the code via submit_code.

A Claude Code plugin for SEO audits: technical SEO, E-E-A-T, schema, local and AI search via parallel subagents

PluginHigh risk16.9K

A Claude Code skill set for auditing sites for AI search: citability, AI crawler access, llms.txt, schema and reports

SkillMedium risk10.6K

The experimental official Google Analytics 4 MCP server: reports, funnels and realtime data on request

MCP serverMedium risk3.2K

Google Search Console MCP

Google Search Console MCP Server for SEOs

An MCP server for Google Search Console: queries and pages with clicks and positions, URL indexing checks, sitemaps and ready SEO skills

MCP serverMedium risk1.5K