网页
综合
更新时间 2026-11-13 17:17:08
PostHog MCP server – Your product data in any AI agent
自动蜘蛛
posthog.com
正文约 5221 字
Are you an agent? Read the plain version.
The PostHog MCP pulls your product data into wherever your agents work. Query analytics, debug errors, roll out flags, and run experiments from any MCP-compatible client.
Are you an agent? Read the plain version.
more insights made by agents through the MCP than by people in the web app, in one month
"But I like the PostHog UI." Then carry on. Try the new navigation beta and tell Surfaces TeamSurfaces Team (they'll be thrilled).
Your agent selects from 1200+ tools across 78 categories, then reads or updates your PostHog project for you.
✻ Welcome to Claude Code!
Any MCP client can connect. PostHog hosts the server, so you run nothing. Sign in with your PostHog account, and it sends you to your US or EU data region.
Want skills too? The PostHog AI plugin installs the same MCP server plus more than 30 PostHog skills in one step. It works in Claude Code, Codex, Cursor, and Gemini CLI. If you connect the server by hand, you get the same tools without the bundled skills.
Build, ship, and measure from one UI. Your agent can find a bug, ship the fix behind a flag, and check the result.
Approve change requests from your agent, and manage access with enterprise-managed authorization.
Ask for MRR, and get the real thing from your semantic layer.
Most agent clients only look up tools as needed (tokenminning is tokenwinning).
Prompts to copy, from one-line questions to multi-step jobs.
Every tool your agent can call, sorted by product.
How sign-in works, what it costs, and how to limit what your agent can touch.
Connect the MCP, then ask your agent to install PostHog in your GitHub repository. The PostHog wizard runs in the cloud, makes the code changes, and opens a pull request for you to review.
The PostHog MCP is a free, hosted Model Context Protocol (MCP) server that lets your AI agent use PostHog. From Claude, Cursor, Codex, VS Code, and other MCP clients, your agent can query analytics, debug errors, roll out feature flags, and run experiments in plain English.
Any AI tool that supports MCP works. We tested and documented setup for Claude Code, Claude Desktop, Cursor, Codex, VS Code, Windsurf, Zed, and PostHog Desktop.
Run npx @posthog/wizard mcp add in your terminal and select your client. The wizard adds the server and signs you in with OAuth. To set it up manually, add the server URL https://mcp.posthog.com/mcp to the MCP settings of your client.
You need a PostHog account, because your agent signs in to it. It is free to sign up. You do not need to install the PostHog SDK to connect the MCP. But to ask questions about your product data, your project must have events. If you do not send events yet, the PostHog Wizard can add the SDK to your app.
Yes. Connecting to the MCP server and calling its tools is free. Standard PostHog usage and billing still apply to the data your queries use. Some tools use LLMs internally and can add PostHog AI spend. Those tools need AI data processing to be enabled in your organization, and they are hidden when it is off.
It can do both. Your agent can read data, for example to run queries, look at errors, or find session replays. It can also make changes, for example to create dashboards and insights, roll out or turn off feature flags, and set up experiments and surveys. If you want your agent to only read data, use read-only mode. It removes the tools that create, update, or delete data.
PostHog AI is the AI agent inside the PostHog app. The PostHog MCP brings PostHog to the AI agent that you already use, such as Claude Code, Cursor, or Codex. Use PostHog AI when you work in PostHog. Use the MCP when you work in your editor, terminal, or chat client and want your agent to use your product data next to your code.
Review tool calls before they run, because an LLM can be tricked into following untrusted commands. You can also limit the session to read-only tools, filter the tools by feature or name, and pin the agent to one organization or project.
No. The server is a proxy to your PostHog instance, and it does not store your analytics data. It routes to the US or EU region of the account you sign in with. Queries run against your project, and the results go straight to your AI client.
Yes. The server allows 480 requests per minute and 4,800 per hour. The limits count per credential, which is the OAuth token or personal API key that your client uses. A request over the limit gets a 429 response with a Retry-After header.
No. OAuth is the recommended way, and the wizard sets it up. If your client does not support OAuth, use a personal API key with the MCP Server preset.
Yes, with one MCP connection for each. A single connection signs in as one account and has one active organization and project.
Multiple accounts and projects
Yes, with the Scale or Enterprise platform add-on. Enterprise-managed authorization (ID-JAG) lets Okta, Entra ID, and other identity providers control MCP access, instead of per-user OAuth or API keys.
Enterprise-managed authorization
For agents waiting to be tool-called into the next chat window. Help yourself to something to read.
Get started – free. One command connects the PostHog MCP to Claude Code, Codex, Cursor, VS Code, and Zed.
本页为82搜索生成的网页快照,内容来自站内索引;演示数据的原文链接仅作示例。