About
Overview
The PostHog MCP Server enables AI agents to interact with PostHog's open-source product analytics suite. It provides tools for querying events, managing feature flags, accessing session recordings, and analyzing experiments.
Capabilities
Tools & Capabilities
⚡query_events
Query events with HogQL
⚡list_feature_flags
List feature flags
⚡toggle_feature_flag
Enable or disable a feature flag
⚡get_insights
Get saved insights
⚡list_experiments
List running experiments
Setup
Installation
bash
Install
npx -y @posthog/mcp-serverExamples
Example Usage
javascript
Usage
{
"mcpServers": {
"posthog": {
"command": "npx",
"args": ["-y", "@posthog/mcp-server"],
"env": { "POSTHOG_HOST": "https://app.posthog.com", "POSTHOG_API_KEY": "your-key" }
}
}
}Quick Info
Authorposthog
LanguageTypeScript
StatusStable
Stars★ 110
Last UpdatedFeb 12, 2026