---
ref: company:posthog
name: PostHog
tools: [tool:posthog/create-cohort, tool:posthog/run-sql-query]
tags: [capability:build-audience, capability:track-product-usage, category:product-analytics, has:api, has:cli, has:mcp]
updated: 2026-09-27
---

# PostHog

Product analytics, session replay, feature flags and experiments on one platform.

PostHog is a product platform that combines product and web analytics, session replay, feature flags, experiments, surveys, error tracking and a CDP in one place.

The API URL above is US Cloud; EU Cloud projects use `https://eu.posthog.com`. The hosted MCP server routes to the right region from the account you sign in with.

The CLI reads its key as `POSTHOG_CLI_API_KEY` and the API as
`POSTHOG_PERSONAL_API_KEY`: each is the name that way's docs use.

## Tools

- tool:posthog/create-cohort — Create a cohort: Creates a cohort of persons from property or behavioral filters, or a static cohort from a list of person IDs.
- tool:posthog/run-sql-query — Run a SQL query: Runs a SQL (HogQL) query over the project's events, persons and other data and returns the rows.

## Links

- Website: https://posthog.com
- Docs: https://posthog.com/docs
