LetPostHogcode

The agent that already understands your context

The answers are already in your data. PostHog AI finds them across your events, replays, errors, logs, and warehouse tables. Ask in PostHog or Slack, or connect your coding agent through MCP.

  • Query product behavior and connected business data
  • Create flags, dashboards, surveys, and alerts
  • Investigate errors and summarize session replays
A hedgehog floating in a ring of dashboards, charts, maps, and logs

More data in, better answers out

Events and replays show what people did. Errors and logs show what broke. Feed PostHog AI the rest of your stack too. Every source you add is more context to answer from.

Plus your warehouse sources

Connect payments, CRM, support, and database tables.

All data sources →

And your code

Connect GitHub, and context can become a pull request. The agent works from your repo and the product data behind it.

Connect GitHub →
Three sample conversations · illustrative data

Illustrative conversation: PostHog AI investigates a drop in billing page upgrades using SQL, the data schema, and session replays. It finds that an annual-first default hurts conversion, recommends a change, and offers to save the work as a notebook. All findings are sample data.

Answers you can trust

Every company counts differently. Without a definition of “active user” or MRR, an AI picks its own, so the same question can give different answers.

With the semantic layer, you define these once (no more re-explaining your data model), and PostHog AI uses your definition every time. Your team signs off on each one, and answers using it are marked as approved.

Set up your definitions →

Slice it any way you like. MRR still means one thing.

Your product data wherever you work

PostHog AI in PostHog Web

Start with a trend, then ask for the SQL behind it, the replays that match, or a survey to learn why. It’s all one conversation, so each question builds on the last.

Knows what you’re looking at

It sees the page you’re on. No need to explain which chart you mean.

Remembers your business

Save what you sell and who your customers are with /remember.

Edits the filters on the page

It edits the filters on your open insight. Tweak a chart by asking.

Writes up notebooks

Notebooks mix text, charts, and replays in one doc. PostHog AI writes them for you.

Try with your data

Opens in your signed-in project.

Also in Slack

Product discussions happen in Slack, so PostHog goes there too. Mention @PostHog in a thread to analyze your data, or to hand a fix to a coding agent.

More about the Slack app →
PostHog Inbox reports posted to a Slack channel, with buttons to review the pull request

PostHog in your coding agent

Plug PostHog into Claude Code, Cursor, or wherever you’re building.

Check before you change

Ask “how often is this endpoint hit?” before you rewrite it.

Size the impact

See how an experiment is trending before you ramp, hold, or roll back.

Verify the deploy

See whether latency or conversion moved before you ship the next thing.

Install the PostHog MCP

npx @posthog/wizard mcp add

Also in your terminal and CI

posthog-cli api gives you the MCP tool catalog as shell commands, including SQL queries.

Read the CLI docs →

Agents that keep working when the chat window is closed

Scouts

Agents that investigate your product on a schedule and file a report when something needs you.

How scouts work →

Inbox

Reports ranked by priority, each with its evidence, plus a pull request when there is a fix.

Reports and pull requests →

Replay Vision

Scanners that watch your session replays for you and turn what they see into data you can query.

How Replay Vision works →

Actual jobs for your AI

Prompts for the work PostHog AI can take off your plate.

Explain the graph everyone is staring at

“How did usage change this week compared to last week? Check errors and replays for a cause.” Try this prompt

Skip to the part where they got stuck

“Find sessions with rage clicks or errors, and summarize what the users were trying to do.” Try this prompt

Find the errors that hit the most users

“Which errors affected the most users this week?” Try this prompt

Read the feedback pile

“Summarize survey responses from the last 30 days.” Try this prompt

Make an opinion testable

“Find a high-traffic page and suggest an A/B test for it. Then draft the experiment.” Try this prompt

Build a dashboard by describing it

“Build a dashboard with daily active users, top pages, and retention.” Try this prompt

More example prompts in the docs →

It’s not magic (but it feels like it)

PostHog AI knows when things break, what users love, and what to build next. Every organization gets 500 free credits a month to ask harder questions that help you build a better product.

The sensible questions

Every organization gets 500 free credits each month, worth $5. After that, 100 credits cost $1. We charge the LLM provider’s cost plus 20%, and you see the cost live as you work. Questions about how to use PostHog are free.

PostHog AI pricing

Yes. PostHog sets a $150 billing limit by default, and you can set your own. When you hit it, AI features pause until your credits reset at the start of the next billing period.

Billing limits

Yes, once. PostHog AI uses outside model providers, so an organization admin has to approve it. The first time you send a chat message, PostHog AI asks the admin to approve. Admins can also switch it on in Settings > Organization > General.

Allow PostHog AI access

It can read your events, persons, sessions, groups, actions, cohorts, data warehouse schema, and saved insights and dashboards. It follows your access controls, so it only sees what you can see. It can also create dashboards, surveys, alerts, and feature flags. For changes in code, it starts a coding task on a repository you connected and tells you when a pull request is ready to review.

Access control

PostHog AI runs on models from Anthropic, OpenAI, and Google, so your messages and the data it reads pass through them. Azure handles semantic search and can see your actions and cohorts. We can’t promise zero data retention yet, because not every model provider offers it.

Subprocessors

Model providers don’t. Our DPA bans them from using your data to train or fine-tune their models. PostHog does train its own models on anonymized data, and you can opt out with the “Enable AI training on anonymized data” setting.

AI data FAQ

An organization admin can switch off PostHog AI data analysis in Settings > Organization > General. While it is off, no data goes to AI providers. You can turn it back on any time, and your chat history stays.


Real things real people really said about PostHog AI (really!)

Pssst, are you Post-It certified?

1 of 11
“I enjoy and trust the experience of PostHog’s AI probably more than Claude just because I feel like it has a little bit more context into all of the events.”
Richard P