{"id":"pg_oozfwmriw1g-","property_id":"prp_rnvsunvhyy60","domain_id":"dom_bjihbbcjezvy","root_domain":"posthog.com","locale":"en","url":"https://posthog.com/mcp","url_hash":"44ec89fc303aec871122b21f1a9e00b5c4442018ab53b7e699453401326f69db","path":"/mcp","depth":1,"canonical_url":"https://posthog.com/mcp","canonical_page_id":null,"page_type":"landing","page_type_guess":"landing","state":"indexed","skip_reason":"budget","priority":"0.9","discovered_via":"sitemap","first_seen_at":"2026-08-27T09:02:49.784Z","last_seen_at":"2026-11-25T11:10:31.176Z","http_status":200,"content_hash":"e5810b457f9823d480c28eaa00de5759473c8776df30bd70451a38f899ed07a5","title":"PostHog MCP server – Your product data in any AI agent","description":"PostHog’s free, hosted MCP server lets your AI agent query analytics, debug errors, roll out flags, and run experiments from Claude, Cursor, Codex, and more.","author":null,"published_at":null,"modified_at":null,"word_count":1061,"reading_time_sec":289,"lang_detected":"en","images":[],"links_out":null,"markdown_source":"readability","refresh_interval":"monthly","last_fetched_at":"2026-11-25T11:08:49.209Z","next_refresh_at":"2026-12-25T11:08:49.209Z","runs_count":1,"changes_count":0,"last_changed_at":null,"fail_count":0,"last_error":null,"created_at":"2026-08-27T09:02:49.784Z","updated_at":"2026-08-27T09:02:49.784Z","inlinks":29,"inlinks_body":29,"outlinks":35,"outlinks_external":3,"anchor_terms":["Hook it up","MCP","PostHog MCP"],"template_score":"1.1153846153846154","cash":"1.507030858865530975","cash_total":"10.981639665954776161","pagerank":"0.0854873871945352","is_orphan":false,"link_confirmed":true,"discovered_wave":0,"embedded_hash":null,"embedded_at":null,"domain_name":"PostHog","brand_color":"#a1b97a","domain_rank":485,"spam_score":9,"markdown":"UsePostHog withoutthe browser\n\n## PostHog, headless\n\nThe 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.\n\n### Install the PostHog MCP\n\n```\nnpx @posthog/wizard mcp add\n```\n\nAre you an agent? [Read the plain version](https://posthog.com/mcp.md).\n\n## You don't need to use PostHog to use PostHog\n\n![SoundBoost](https://posthog.com/static/soundboost-light-187338acb27e698cdd1d212d137cc32f.svg)\n*Read the story*\n\nLezgin Zilan\n\nCTO, Qred\n\n> “Hell yes, I'd recommend PostHog. \\[…\\] Especially the MCP.”\n\n[Read the story](https://posthog.com/customers/qred)\n\n![PostHog](https://posthog.com/brand/posthog-logo.svg)\n*Read the post*\n\n**\"But I like the PostHog UI.\"** Then carry on. Try the [new navigation beta](https://posthog.com/roadmap?feature=today-rail-nav) and tell [![Surfaces mini crest](https://res.cloudinary.com/dmukukwp6/image/upload/f_png,h_20,w_20,c_fill,g_auto,q_auto/posthog_code_mini_crest_693227eecb?_a=AXAH4nI0)Surfaces Team![Surfaces mini crest](https://res.cloudinary.com/dmukukwp6/image/upload/f_png,h_20,w_20,c_fill,g_auto,q_auto/posthog_code_mini_crest_693227eecb?_a=AXAH4nI0)Surfaces Team](https://posthog.com/teams/surfaces) (they'll be thrilled).\n\n## What can you do with the PostHog MCP?\n\nYour agent selects from 1300+ tools across 79 categories, then reads or updates your PostHog project for you.\n\nclaude — ~/hogflix\n\n✻ Welcome to **Claude Code**!\n\ncwd: ~/hogflix\n\n\\>\n\n? for shortcuts\n\n## Which agents can use it?\n\nAny 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.\n\n-   [ChatGPTPlugin](https://chatgpt.com/plugins/plugin_asdk_app_699caef2d680819188727b0ddbb349dd)\n-   [ClaudeConnector directory](https://claude.ai/directory/connectors/posthog)\n-   [CursorSetup guide](https://posthog.com/docs/model-context-protocol/cursor)\n-   [CodexSetup guide](https://posthog.com/docs/model-context-protocol/codex)\n-   [VS CodeSetup guide](https://posthog.com/docs/model-context-protocol/vscode)\n-   [WindsurfSetup guide](https://posthog.com/docs/model-context-protocol/windsurf)\n-   [ZedSetup guide](https://posthog.com/docs/model-context-protocol/zed)\n-   [Gemini CLIAI plugin](https://github.com/PostHog/ai-plugin)\n\nWant skills too? PostHog [skills](https://posthog.com/docs/skills) ship with the MCP server, so there's nothing extra to install. Once your agent is connected, it loads the skill it needs when a task calls for it.\n\nPart of a balanced agent's [diet](https://posthog.com/mcp/leaderboard \"MCP leaderboard\")\n\n## Your agent gets the full spread\n\nEvery product, read and write\n\nBuild, ship, and measure from one UI. Your agent can find a bug, ship the fix behind a flag, and check the result.\n\nUses your metric definitions\n\nAsk for MRR, and get the real thing from your [semantic layer](https://posthog.com/docs/semantic-layer).\n\nLight on context\n\nMost agent clients only look up tools as needed (tokenminning is tokenwinning).\n\n### MCP tools reference\n\nEvery tool your agent can call, sorted by product.\n\n[See every tool →](https://posthog.com/docs/model-context-protocol/tools)\n\n### FAQ and advanced setup\n\nHow sign-in works, what it costs, and how to limit what your agent can touch.\n\n[Read the FAQ →](https://posthog.com/docs/model-context-protocol/faq)\n\n## No PostHog in your app yet? Your agent can add it\n\nConnect the MCP, then ask your agent to install PostHog in your GitHub repository. The [PostHog wizard](https://posthog.com/docs/ai-engineering/ai-wizard) runs in the cloud, makes the code changes, and opens a pull request for you to review.\n\n### Install the PostHog MCP\n\n```\nnpx @posthog/wizard mcp add\n```\n\nSome assembly required (by your agent)\n\n## Questions people ask before connecting\n\nThe 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.\n\n[Setup guide](https://posthog.com/docs/model-context-protocol)\n\nAny 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.\n\n[Supported clients](https://posthog.com/docs/model-context-protocol/faq#which-ai-clients-and-editors-are-supported)\n\nRun 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.\n\n[Client setup guides](https://posthog.com/docs/model-context-protocol)\n\nYou 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.\n\n[Install PostHog](https://posthog.com/docs/getting-started/install)\n\nYes. 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.\n\n[Cost details](https://posthog.com/docs/model-context-protocol/faq#how-much-does-it-cost)\n\nIt 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.\n\n[All MCP tools](https://posthog.com/docs/model-context-protocol/tools)\n\nPostHog 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.\n\n[About PostHog AI](https://posthog.com/docs/posthog-ai)\n\nReview 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.\n\n[Read-only mode](https://posthog.com/docs/model-context-protocol/faq#restricting-to-read-only-mcp-tools)\n\nNo. 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.\n\n[Data and privacy](https://posthog.com/docs/model-context-protocol/faq#where-is-my-data-sent)\n\nYes. 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.\n\n[Rate limits](https://posthog.com/docs/model-context-protocol/faq#are-there-rate-limits)\n\nNo. 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.\n\n[API key setup](https://posthog.com/docs/model-context-protocol/faq#using-an-api-key-instead-of-oauth)\n\nYes, with one MCP connection for each. A single connection signs in as one account and has one active organization and project.\n\n[Multiple accounts and projects](https://posthog.com/docs/model-context-protocol/faq#working-with-multiple-accounts-organizations-or-projects)\n\nYes, 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.\n\n[Enterprise-managed authorization](https://posthog.com/docs/model-context-protocol/enterprise-managed-authorization)\n\n## The waiting room\n\nFor agents waiting to be tool-called into the next chat window. Help yourself to something to read.\n\nGo on, pick one up.\n\n## Don't keep your agent waiting\n\n**Get started – free.** One command connects the PostHog MCP to Claude Code, Codex, Cursor, VS Code, and Zed.\n\n### Install the PostHog MCP\n\n```\nnpx @posthog/wizard mcp add\n```","storage":{"htmlKey":"stealpage/html/posthog.com/pg_oozfwmriw1g-/run_y7zcfapmhasq.html.gz","markdownKey":"stealpage/md/posthog.com/pg_oozfwmriw1g-/run_y7zcfapmhasq.md.gz"},"facets":null,"assets":[{"kind":"image","src_url":"https://posthog.com/images/og/default.png","r2_key":null,"alt":null,"caption":null,"width":null,"height":null,"is_hero":true,"zone":"main"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/w_1780,q_auto,f_auto/9000_hogzilla_359a450fb3.png","r2_key":null,"alt":"","caption":null,"width":1780,"height":868,"is_hero":false,"zone":"unknown"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/w_2967,q_auto,f_auto/9000_monopoly_light_6614a8a5d5.jpg","r2_key":null,"alt":"","caption":null,"width":2967,"height":1463,"is_hero":false,"zone":"unknown"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/w_1582,q_auto,f_auto/9000_monopoly_dark_26c85ccad8.jpg","r2_key":null,"alt":"","caption":null,"width":1582,"height":780,"is_hero":false,"zone":"unknown"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/w_997,q_auto,f_auto/office_cc4ae8675f.png","r2_key":null,"alt":"","caption":null,"width":997,"height":858,"is_hero":false,"zone":"unknown"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/w_800,q_auto,f_auto/9000_hedge_light_42c729131e.png","r2_key":null,"alt":"","caption":null,"width":1555,"height":1262,"is_hero":false,"zone":"unknown"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/w_800,q_auto,f_auto/9000_hedge_dark_b36706e924.png","r2_key":null,"alt":"","caption":null,"width":1555,"height":1262,"is_hero":false,"zone":"unknown"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/demo_light_2008b30494.png","r2_key":null,"alt":"","caption":"Demo","width":62,"height":43,"is_hero":false,"zone":"nav"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/demo_dark_6f25a1ecb2.png","r2_key":null,"alt":"","caption":"Demo","width":62,"height":43,"is_hero":false,"zone":"nav"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/c_scale,w_800/headless_horsehog_17d1541713","r2_key":null,"alt":"A hedgehog dressed as the headless horseman, riding a toy horse and holding a flaming pumpkin","caption":null,"width":null,"height":null,"is_hero":false,"zone":"main"},{"kind":"image","src_url":"https://posthog.com/static/soundboost-light-187338acb27e698cdd1d212d137cc32f.svg","r2_key":null,"alt":"SoundBoost","caption":"Read the story","width":null,"height":null,"is_hero":false,"zone":"main"},{"kind":"image","src_url":"https://posthog.com/static/soundboost-dark-bb23ea216d2412ce04437d9f079905ea.svg","r2_key":null,"alt":"SoundBoost","caption":"Read the story","width":null,"height":null,"is_hero":false,"zone":"main"},{"kind":"image","src_url":"https://posthog.com/brand/posthog-logo.svg","r2_key":null,"alt":"PostHog","caption":"Read the post","width":null,"height":null,"is_hero":false,"zone":"main"},{"kind":"image","src_url":"https://posthog.com/brand/posthog-logo-white.svg","r2_key":null,"alt":"PostHog","caption":"Read the post","width":null,"height":null,"is_hero":false,"zone":"main"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/f_png,h_20,w_20,c_fill,g_auto,q_auto/posthog_code_mini_crest_693227eecb?_a=AXAH4nI0","r2_key":null,"alt":"Surfaces mini crest","caption":null,"width":null,"height":null,"is_hero":false,"zone":"main"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/Stripe_Logo_revised_2016_24183d3284.svg","r2_key":null,"alt":"","caption":null,"width":null,"height":null,"is_hero":false,"zone":"main"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/c_scale,w_800/posthog_toast_hog_a271b970dd","r2_key":null,"alt":"ToastHog","caption":"Part of a balanced agent's diet","width":null,"height":null,"is_hero":false,"zone":"main"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/c_scale,w_600/Group_144404_d649bc516c","r2_key":null,"alt":"A hedgehog toy with its arm, ear, shoe, and hat in pieces on the floor around it","caption":"Some assembly required (by your agent)","width":null,"height":null,"is_hero":false,"zone":"main"},{"kind":"image","src_url":"https://res.cloudinary.com/dmukukwp6/image/upload/c_scale,w_300/sitting_reading_hog_abeb5be4fe","r2_key":null,"alt":"","caption":null,"width":null,"height":null,"is_hero":false,"zone":"main"}],"shots":[{"viewport":"mobile","width":390,"height":844,"r2_key":"stealpage/shots/posthog.com/pg_oozfwmriw1g-/run_y7zcfapmhasq-mobile.png","phash":"b086cac000cd090f","visual_delta":null,"captured_at":"2026-11-25T11:08:54.482Z"},{"viewport":"desktop","width":1440,"height":900,"r2_key":"stealpage/shots/posthog.com/pg_oozfwmriw1g-/run_y7zcfapmhasq-desktop.png","phash":"074d4c1d1d632629","visual_delta":null,"captured_at":"2026-11-25T11:08:54.004Z"}],"history":[{"id":"run_y7zcfapmhasq","started_at":"2026-11-25T11:08:49.204Z","http_status":200,"fetcher":"direct","changed":false,"diff":null,"word_count":1061}],"citedBy":[{"id":"pg_qkzaot221ktn","url":"https://posthog.com/about","title":"About PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_gr_3sa8sozut","url":"https://posthog.com/products","title":"Products – PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_y9fp1qdqpiop","url":"https://posthog.com/blog/all/14","title":"All Blog posts - PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_xs3wvvp2ifj_","url":"https://posthog.com/demo","title":"Demo - PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_kxqb7f7rcei0","url":"https://posthog.com/docs","title":"PostHog Docs","anchors":["MCP"],"zone":"main"},{"id":"pg_wgkvlqtxi9v_","url":"https://posthog.com/error-tracking","title":"Error Tracking – Error monitoring and alerts | PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_qyahn5mzpueb","url":"https://posthog.com/surveys","title":"Surveys – Collect product feedback with PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_hdre3ntwjbgj","url":"https://posthog.com/handbook/people/compensation","title":"Compensation - Handbook - PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_i8eadp7qehus","url":"https://posthog.com/merch","title":"Merch - PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_tgqauszyuclq","url":"https://posthog.com/self-driving","title":"Self-driving – Proactive fixes from product data | PostHog","anchors":["MCP","PostHog MCP","Hook it up"],"zone":"main"},{"id":"pg_nbkyvrndvwfk","url":"https://posthog.com/handbook/marketing","title":"Overview - Handbook - PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_rou6t5xskqtq","url":"https://posthog.com/trash","title":"Trash - PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_ul17qj4xoc7z","url":"https://posthog.com/docs/self-driving/inbox","title":"Inbox - Docs - PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_ros_uzqbuuau","url":"https://posthog.com/session-replay","title":"Session Replay – Record and watch user sessions | PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_5phwzcecs9tj","url":"https://posthog.com/web-analytics","title":"Web Analytics – Privacy-friendly website analytics | PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_ekionounvsnx","url":"https://posthog.com/handbook/why-does-posthog-exist","title":"Why does PostHog exist? Our mission and strategy - Handbook - PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_3-ie7s8ecp63","url":"https://posthog.com/handbook","title":"Handbook - PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_o-gg6pjqgkxx","url":"https://posthog.com/talk-to-a-human","title":"Talk to a human – Book a PostHog demo","anchors":["MCP"],"zone":"main"},{"id":"pg__63x4zsymcey","url":"https://posthog.com/docs/model-context-protocol","title":"Model Context Protocol (MCP) - Docs - PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_r252fllprodd","url":"https://posthog.com/","title":"PostHog – Your product’s context layer","anchors":["MCP"],"zone":"main"},{"id":"pg_wg8b-31qbsmo","url":"https://posthog.com/changelog","title":"Changelog - PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_icgynwacldcl","url":"https://posthog.com/careers","title":"Careers - PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_q4cmvb4hm1sx","url":"https://posthog.com/ai-observability","title":"AI Observability – LLM tracing, evals, and costs | PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_gmb93uoz0py8","url":"https://posthog.com/feature-flags","title":"Feature Flags – Ship safely and control rollouts with PostHog","anchors":["MCP"],"zone":"main"},{"id":"pg_h3o8ejrq0bzn","url":"https://posthog.com/workflows","title":"Workflows – Automate emails and messages from user behavior","anchors":["MCP"],"zone":"main"}]}