Integrations
Allows to list PostHog projects and create annotations in PostHog projects with optional timestamps directly through Claude Desktop
PostHog MCP Server 📊
A Model Context Protocol (MCP) server for interacting with PostHog. Create annotations and manage projects directly through Claude Desktop!
Features 🚀
- List Projects: View all available PostHog projects in your organization
- Create Annotations: Add annotations to your PostHog projects with optional timestamps [this list can be much longer, anything our api has basically...]
Setup 🛠️
- Prerequisites
- Python 3.10 or higher
uv
package manager- PostHog API Key with
annotation:write
andproject:read
scopes obtained from your project settings
- InstallationCopy
- Configuration
- Create a
.env
file in the project root:Copy
- Create a
- Claude Desktop Setup
- Install Claude Desktop
- Open Claude Desktop settings and click "Edit Config". Alternatively, you can open the file from:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json
- Windows:
%APPDATA%\Claude\claude_desktop_config.json
- macOS:
- Add this to your
claude_desktop_config.json
(adjust paths according to your system):Check the latest documentation on setting up Claude Desktop as MCP client if you ran into any issues.Copy
Usage 💡
After setup, you'll see a hammer 🔨 icon in Claude Desktop. The following commands are available:
List Projects
Ask Claude:
Get and Search for Insights
Ask Claude:
"List my PostHog insights" or "Search for revenue insights in my PostHog"
Search for documentations online
You can ask:
- "how can i do reverse proxy in nextjs in posthog?"
Create Annotation
Using the Project ID you get from the list of projects, ask Claude:
or with a specific date:
Troubleshooting 🔍
- If the hammer icon doesn't appear, restart Claude Desktop
- Check logs at
~/Library/Logs/Claude/mcp*.log
(macOS) or%APPDATA%\Claude\logs
(Windows) - Verify your PostHog API key has the correct permissions
- Make sure all paths in
claude_desktop_config.json
are absolute paths
Contributing 🤝
Feel free to open issues and PRs! We follow PostHog's contribution guidelines.
You must be authenticated.
local-only server
The server can only run on the client's local machine because it depends on local resources.
A Model Context Protocol server that enables Claude Desktop users to interact directly with PostHog, allowing them to view projects and create annotations through natural language commands.
Related Resources
Related MCP Servers
- -securityFlicense-qualityA Model Context Protocol server for Claude Desktop that provides structured memory management across chat sessions, allowing Claude to maintain context and build a knowledge base within project directories.Last updated -TypeScript
- -securityFlicense-qualityA Model Context Protocol server that allows Claude to interact with Warpcast accounts, enabling actions like posting casts, reading content, searching by keywords, and managing channel interactions through natural language.Last updated -1JavaScript
- AsecurityAlicenseAqualityA collection of Model Context Protocol servers that enable Claude Desktop to provide development assistance capabilities with filesystem, Git, shell command, and web search functionality without incurring API usage costs.Last updated -214TypeScriptMIT License
- -securityAlicense-qualityA Model Context Protocol server that allows Claude Desktop to manage and execute tasks in a queue-based system, supporting planning, execution, and completion phases.Last updated -3222TypeScriptMIT License