query-examples

Provide HogQL query examples and schema references for PostHog data analysis.

693|111|Updated Aug 11, 2020
One-click install
npx skills add https://github.com/PostHog/posthog-foss --skill query-examples
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: query-examples
Source: https://github.com/PostHog/posthog-foss/tree/main/products/posthog_ai/skills/query-examples
Command: npx skills add https://github.com/PostHog/posthog-foss --skill query-examples

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides ready-to-use HogQL query examples and comprehensive documentation to help you effectively analyze your PostHog data, whether it's for product analytics or system insights.

Core Features & Use Cases

  • Analytics Query Examples: Find pre-written queries for trends, funnels, retention, user paths, and more.
  • Data Schema Reference: Understand the structure of PostHog's system and captured data models.
  • HogQL Functionality: Learn about HogQL syntax differences, extensions, and available functions.
  • Use Case: You need to understand user retention over the next 12 weeks. You can quickly find and adapt the "Retention (unique users, returned to perform an event in the next 12 weeks, recurring)" example query.

Quick Start

Use the query-examples skill to find an example for analyzing user retention.

Frequently Asked Questions about query-examples

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write HogQL queries for PostHog product analytics?

You can write HogQL queries for PostHog product analytics by using a comprehensive library of ready-to-use examples, covering trends, funnels, retention, and user paths, which you can quickly adapt for your specific data analysis needs.

Where can I find HogQL query examples for user retention analysis?

HogQL query examples for user retention analysis are provided as pre-written templates, such as querying unique users who returned to perform an event in the next 12 weeks, allowing you to easily modify and apply them to your dataset.

What is the data schema structure for PostHog insights and feature flags?

The PostHog data schema structure for insights, dashboards, and feature flags is detailed in comprehensive reference materials, helping you understand the system and captured data models required for accurate HogQL data analysis.

Does this Skill include HogQL syntax guides and function references?

Yes, this Skill includes detailed HogQL syntax guides that explain differences, extensions, and available functions, ensuring you understand the exact syntax required to execute complex queries on your PostHog data.

Can I analyze user paths and funnels using pre-written PostHog queries?

You can analyze user paths and funnels using a library of pre-written PostHog queries, enabling you to quickly retrieve behavioral data and understand user flows without needing to construct complex HogQL syntax from scratch.