.fyi
SkillsMCPPluginsSubagents

Browse by category

DevOps & CI/CD SkillsProductivity & Workflow SkillsOther SkillsProduct & Project Management SkillsDocumentation & Knowledge SkillsCode Review & Refactor SkillsBackend & APIs SkillsAgent Meta & Communication SkillsResearch SkillsSecurity SkillsUX UI & Design SkillsTesting & QA SkillsSee all →

Every Claude Code skill, MCP server, plugin and subagent in one directory. Searchable, comparable, and one command from installed. Live stats from GitHub, npm and PyPI.

We're on Product HuntYour agent's app storeCheck it out →
Agent SkillsMCP ServersPluginsSubagentsCoding Agents
CollectionsOfficial publishersGlossaryFAQBlogSearchSavedFeedback
PrivacyTermsllms.txtSitemap

made with ♥ · © 2026 aaaa.fyi

Independent project · real data from public registries

…/posthog/ai-plugin
home/mcp-servers/posthog/ai-plugin
posthog avatar

ai-plugin

byposthog· 1 MCP server

Stars

64

Forks

12

Category

AI Agents & MCP

View on GitHub

TL;DR

Official PostHog plugin for Claude Code, Cursor, Gemini, Codex and other AI coding tools

How to install ai-plugin?

posthog/ai-plugin
$git clone https://github.com/posthog/ai-plugin

Installs into the current project.

›Prefer a prompt? Paste this to your agent

Install & use

Install ai-plugin by running `git clone https://github.com/posthog/ai-plugin`, then use it for the current task and follow its documentation at https://github.com/posthog/ai-plugin.

Files · 1

View on GitHub
README.md
1# PostHog AI plugin
2 
3Official PostHog plugin for AI clients. Access PostHog products directly from your AI coding tool.
4 
5## Installation
6 
7### Claude Code
8 
91. Install the plugin:
10 ```bash
11 claude plugin install posthog
12 ```
13 
142. Authenticate via OAuth:
15 ```bash
16 # Just enter Claude Code anywhere
17 claude
18 # Then, use the /mcp command within Claude, select plugin:posthog:posthog, and press Enter
19 /mcp
20 ```
21 Then follow the browser prompts to log into PostHog.
22 
233. (Optional) Send Claude Code sessions to PostHog LLM Analytics.
24 
25 Add to `~/.claude/settings.json` (global) or `.claude/settings.local.json` (per-project):
26 ```json
27 {
28 "env": {
29 "POSTHOG_LLMA_CC_ENABLED": "true",
30 "POSTHOG_API_KEY": "phc_...",
31 "POSTHOG_HOST": "https://eu.i.posthog.com"
32 }
33 }
34 ```
35 
36 Both `POSTHOG_LLMA_CC_ENABLED=true` and `POSTHOG_API_KEY` are required. Sessions are sent when Claude Code exits. Set `POSTHOG_LLMA_PRIVACY_MODE=true` to redact prompt/output content. Add custom properties to all events with `POSTHOG_LLMA_CUSTOM_PROPERTIES` (JSON string, e.g. `'{"ai_product": "my-app"}'`). Set `POSTHOG_AI_PURPOSE` to declare what the session is doing relative to the repo — documented values are `authoring` and `review`, emitted as `$ai_purpose`. Useful when a harness wraps an agent it can't modify (e.g. a CI job running Claude Code as a reviewer); left unset the property is omitted.
37 
38### Cursor
39 
40Install from the [Cursor Marketplace](https://cursor.com/marketplace) or add manually in Cursor Settings > Plugins.
41 
42### Codex
43 
441. Add the marketplace:
45 ```bash
46 codex plugin marketplace add PostHog/ai-plugin
47 ```
48 
492. Install the plugin from inside Codex:
50 ```
51 codex
52 # Then run /plugins, select PostHog, and install
53 /plugins
54 ```
55 
56### Gemini CLI
57 
58```bash
59gemini extensions install https://github.com/PostHog/ai-plugin
60```
61 
62### Grok
63 
641. Install the plugin:
65 ```bash
66 grok plugin install PostHog/ai-plugin --trust
67 ```
68 
692. Authenticate via OAuth:
70 
71 On first use of a PostHog tool, Grok prompts you to authorize in your browser. Log into PostHog to connect.
72 
73## How to develop
74 
751. Clone and install the plugin:
76 ```bash
77 git clone https://github.com/PostHog/ai-plugin
78 claude --plugin-dir ./ai-plugin
79 ```
80 
812. Authenticate via OAuth:
82 ```
83 /mcp
84 ```
85 Then follow the browser prompts to log into PostHog.
86 
87## Features
88 
89This plugin provides access to 27+ PostHog tools across these categories:
90 
91- **Feature flags** - Create, update, and manage feature flags
92- **Experiments** - Run and analyze A/B tests
93- **Insights** - Query analytics and create visualizations
94- **Dashboards** - Manage dashboards and add insights
95- **Error tracking** - View and debug errors
96- **LLM analytics** - Track AI/LLM costs and usage
97- **Documentation** - Search PostHog docs
98- And more
99 
100### Bundled skills
101 
102The plugin also ships 30+ task-specific skills that your AI client loads on demand to follow PostHog best practices — covering HogQL query patterns, experiment creation and lifecycle, feature flags, data warehouse setup and troubleshooting, LLM analytics exploration, session replay diagnostics, and SDK instrumentation. Skills activate automatically when their description matches your request (e.g. "create an experiment", "why isn't my Stripe sync working?", "audit my feature flags"), so you generally don't need to invoke them by name.
103 
104## Example usage
105 
106```
107> What feature flags do I have?
108> Create a feature flag called new-onboarding for 50% of users
109 
110> Show me errors from the last 24 hours
111> Which errors are affecting the most users?
112 
113> How many users signed up this week?
114> What's the conversion rate for the checkout funnel?
115 
116> Show me all my experiments
117> What are the results of the checkout-flow experiment?
118 
119> Create a new dashboard called Product Metrics
120> Add the signup funnel insight to the Growth dashboard
121 
122> What are the responses to the NPS survey?
123> Create a feedback survey for the checkout page
124 
125> What's my most triggered event?
126> Show me the top 10 pages by pageviews
127```
128 
129## Self-hosted
130 
131For self-hosted PostHog instances, set the `POSTHOG_MCP_URL` environment variable to point to your instance:
132 
133```bash
134export POSTHOG_MCP_URL="https://mcp.your-posthog-instance.com/mcp"
135```
136 
137## Documentation
138 
139- [PostHog MCP documentation](https://posthog.com/docs/model-context-protocol)
140- [PostHog API documentation](https://posthog.com/docs/api)
141 
142## License
143 
144MIT

Preview

posthog/ai-pluginposthog/ai-plugin
Repoposthog/ai-plugin
TypeMCP Servers
CategoryAI Agents & MCP
UpdatedJul 2026
License—
First seenJul 27, 2026

Tags

MCP

Related

6 picks
Type
  1. langchain-ai avatarlangchain-mcp-adaptersMake Anthropic Model Context Protocol (MCP) tools compatible with LangChain and LangGraph agents.MCP ServersJul 20267.0M3.6k
  2. openclaw avatarmcporterTypeScript runtime and CLI for connecting to configured Model Context Protocol servers.MCP ServersJul 20262.5M4.8k
  3. sparfenyuk avatarmcp-proxyA MCP server which proxies requests to a remote MCP server over streamable HTTP or SSE.MCP ServersJul 20262.2M2.7k
  4. sooperset avatarmcp-atlassianThe Model Context Protocol (MCP) Atlassian integration is an open-source implementation that bridges Atlassian products (Jira and Confluence) with AI language models following Anthropic's MCP specification.MCP ServersJul 20261.7M5.6k
  5. open-webui avataropen-webuiOpen WebUIMCP ServersJul 20261.4M147k
  6. dyoshikawa avatarrulesyncUnified AI rules management CLI tool that generates configuration files for various AI development toolsMCP ServersJul 2026889k1.3k