Meet your users without leaving your editor
PostHog MCP plugs your product data directly into Claude Code, Cursor, Codex, and Windsurf. Ask why sign-ups dropped, build a funnel, or write a retention query. All from the same tools you ship with. No dashboard spelunking required.
Connect PostHog MCP to Cursor, Claude Code, Codex, or Windsurf and query your product data without leaving your editor. First 1M events/month are free. No credit card, no per-seat pricing.

A few PostHog Product Analytics customers.
(Yes they actually use us, no it's not just some random engineer who tried us out 2+ years ago.)
Install with the PostHog Wizard
PostHog Wizard analyzes your codebase and automatically sets up autocapture, custom events, and dashboards tailored to your product. One command does it all:
Install PostHog with one command
Paste this into your terminal and make AI do all the work.

Autocapture is on by default. Pageviews, clicks, form submissions, and session data are tracked automatically the moment a user lands on your page. No manual event tagging required.
Call posthog.capture() for custom events, or define events retroactively using actions — no re-deploy needed.
Or install the SDK directly
Analyze with MCP and AI
MCP (Model Context Protocol) connects your AI coding agent directly to your PostHog data. Point Claude Code, Cursor, Zed, or Windsurf at the PostHog MCP server and ask questions about your product without opening a single dashboard.
Install in 30 seconds
Try prompts like
- "Why did sign-ups drop 12% last Tuesday?"
- "Build me a funnel from landing page to paid conversion, broken down by marketing source."
- "Which features do my power users engage with most?"
- "Show me weekly retention for users who completed onboarding vs. those who didn't."
- "Create a trend showing daily active users broken down by plan, then save it as a dashboard."
Or use PostHog AI inside the app
Can't find the right insight? Just ask. PostHog AI knows your data and can build dashboards, create retention curves, write SQL, and surface patterns you'd otherwise miss.


See it in action
Watch a full walkthrough of PostHog's product analytics: from capturing your first event to building funnels, digging into retention, and handing off context to your AI agent.
- Autocapture and custom event setup
- Trends, funnels, retention, and user paths
- Group analytics for B2B companies
- PostHog AI and MCP for natural language queries
Explore the analytics suite
PostHog ships the full analytics toolkit: funnels, retention, user paths, lifecycle charts, correlation analysis, stickiness, and HogQL. Pick the right lens for any question.
Funnels
See exactly where users drop off. Correlation analysis automatically surfaces what makes users convert — without you having to guess. Jump directly from any funnel step to watch session recordings for those exact users.

Trends
Standard line and bar charts, plus formula mode for ratios like DAU/MAU. Break down by any property. Built-in sampling for billions of events, so you always get fast answers.

Retention
Define what "return" means for your product and compare cohorts. Click any data point to see the actual users behind it — way more flexible than standard retention charts.

User paths
See the actual routes users take through your product. Start anywhere, end anywhere. Use wildcards to group similar pages together. Great for finding unexpected behavior you'd never think to look for.

SQL
Write HogQL queries directly against your event data. No separate data warehouse needed — though PostHog works with yours if you have one. Escape the drag-and-drop when you need full power.

Built for how engineering teams work
PostHog is designed to be queried, not just watched. Here's how engineering teams actually use it:
Funnels → Session Replay
Click any funnel drop-off to land directly in a playlist of session recordings for those exact users. See what they saw, what they clicked, and what confused them. No CSV export, no matching IDs.
Feature flag + event targeting
Roll out features with Feature Flags and use product events as release conditions. Target your 10% power users, measure activation, and revert without a full deploy.


B2B group analytics
Track metrics at the company or team level, not just individual users. Measure activation, retention, and churn by account — essential for B2B SaaS.


Questions engineers ask us
Real questions from engineers and founders — with links to step-by-step tutorials and docs.
Use for free
PostHog's Product Analytics is built to be cost-effective by default, with a generous free tier and transparent usage-based pricing. Since we don't charge per seat, more than 90% of companies use PostHog for free.
TL;DR 💸
- No credit card required to start
- First 1 million events per month are free
- Above 1M we have usage-based pricing at $0.000015/event with discounts
- PostHog MCP is included (no enterprise plan required)
- Set billing limits to avoid surprise charges
- See our pricing page for more up-to-date details
That's it! You're ready to start integrating.
You made it to the bottom. That makes you special. At least to us. So here's a special sign.

Try PostHog Code for free. It's very special. Just like you. See for yourself.