Cohorts enable you to easily create a list of users who have something in common, such as completing an action or having the same property.
Here are a few examples of the cohorts you can create:
- Users who work at the same company.
- Users who used your app in the last week.
- Users who have churned from your product.
- Users who signed up recently.
- Users who viewed the signup page, but didn't convert.
- "Are people at company X using our app frequently?"
- "What percentage of the users who signed up last week are still using our app?"
- "Which features are our power users using?"
Cohorts vs. groups
Cohorts are often confused with groups, but they each serve different purposes:
- Cohorts represent a specific set of users – e.g., a list of users that all belong to the same company.
- Groups aggregate events based on entities, such as organizations or companies, and do not necessarily connect to a user. They enable you to analyze trends, insights, and dashboards at an entity-level, as opposed to a user-level.
Groups require additional code in your app to set up, while cohorts are created in PostHog and don't require additional code. This makes cohorts easier to use and quicker to get started. If your only goal is to create a list of users with something in common, we recommend cohorts instead of groups.
How to create a cohort
There are two methods to create a new cohort:
Method 1: Create a new cohort directly from an insight
Step 2: In the modal popup, click 'Save as cohort' in the bottom right.
The video below shows how to create a new cohort from a trend, although you can similarly create a cohort from a funnel, user path, or any other insight.
Method 2: Create a new cohort from the cohorts page
Step 1: Navigate to the Cohorts page in the sidebar:
Step 2: Click '+ New Cohort' on the top right.
Static vs. dynamic cohorts
When creating a cohort, you'll choose between a static or dynamic cohort:
Static cohorts are lists of users that do not change over time. For example, all users who signed up for your app in January 2023.
Static cohorts are created from insights, or by uploading a csv of users. The CSV file only requires a single column with the user’s distinct ID. The very first row (the header) will be skipped during import.
To update the list, you can either upload another CSV to add more users, or use the interface to remove users.
Dynamic cohorts are defined by a continuously evaluated condition. This means that the members of the cohort can change over time. For example, a dynamic cohort could be all users who have have used a certain feature in your app.
Dynamic cohorts are created by matching users who meet a certain criteria. You can define this criteria by combining any number of the following conditions:
- Users who have performed a specific event or action within a certain time frame.
- Users who have certain properties.
- Users based on their lifecycle event. For example, users who have recently stopped performing an event.
- Users matching other cohorts.
Want to know more about what's possible with Cohorts in PostHog? Try these tutorials:
Want more? Check our full list of PostHog tutorials.