> ## Documentation Index
> Fetch the complete documentation index at: https://mintlify.com/mixpanel/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Cohorts

> Group users by demographic and behavior

# Cohorts: Group Users by Behavior

Cohorts are groups of users that share a set of properties or perform a similar sequence of events. Mixpanel lets you visually define cohorts, view the users in them, compare them in analysis, and share them across your organization.

## What are Cohorts?

Cohorts represent user segments based on who they are or what they do:

**Demographic Cohorts:**

* **US Users** - Users from the United States
* **Premium Subscribers** - Users with premium plans
* **Mobile Users** - Users on mobile devices

**Behavioral Cohorts:**

* **New Users** - Signed up in the past month
* **Power Users** - Used app on 5 of last 7 days
* **Dropped-Off Users** - Signed up but didn't return
* **High-Value Customers** - Spent over \$500 lifetime

## Use Cases

Cohorts enable powerful segmentation and targeting:

### Analysis and Insights

* Compare power users vs casual users
* Track new user growth over time
* Analyze retention by acquisition channel
* Identify high-value customer behaviors

### Marketing and Messaging

* Target campaigns to specific user segments
* Re-engage churned users
* Personalize messaging by user type
* Exclude existing customers from acquisition ads

### Product Development

* Test features with beta user cohort
* Measure feature adoption by segment
* Understand different user personas
* Prioritize based on segment size

## Creating Cohorts

There are three main ways to create cohorts:

### 1. From a Report

Click any data point in Insights, Funnels, or Retention:

1. Click a bar, point, or segment
2. Select **View Users**
3. Click **Save as Cohort**
4. Name your cohort

**Example:** In a funnel report, click users who dropped off at checkout to create a "Checkout Abandoners" cohort.

### 2. Using the Cohort Builder

The [Cohort Builder](https://mixpanel.com/report/users) lets you define precise conditions:

**Filter by Event Behavior:**

<img src="https://mintlify.s3.us-west-1.amazonaws.com/mixpanel-docs/cohort_example_1.gif" alt="Cohort Example 1" />

**Example:** Users who watched more than 10 videos in the last 7 days

**Filter by First-Time Actions:**

<img src="https://mintlify.s3.us-west-1.amazonaws.com/mixpanel-docs/cohort_example_2.gif" alt="Cohort Example 2" />

**Example:** Users who watched a video for the first time in the past 30 days

**Chain Multiple Conditions:**

<img src="https://mintlify.s3.us-west-1.amazonaws.com/mixpanel-docs/cohort_example_3.gif" alt="Cohort Example 3" />

**Example:** Power users who are also premium subscribers

<Note>
  You can access the Cohort Builder from any report by clicking **Create Custom > Cohort** in the query builder.
</Note>

### 3. From a CSV File

Upload a list of user IDs to create a cohort:

**Use Cases:**

* Random sample selections
* External data sources
* Lists from other tools
* Custom user groups

**Steps:**

1. Create CSV with two columns:
   * Column 1: `$distinct_id` values
   * Column 2: Property value (e.g., "inCohort" = "yes")

<img src="https://mintlify.s3.us-west-1.amazonaws.com/mixpanel-docs/cohort_csv1.png" alt="CSV Example" />

2. Go to **Users** → **Add/Edit Profile** → **Import from CSV**

<img src="https://mintlify.s3.us-west-1.amazonaws.com/mixpanel-docs/cohort_csv2.png" alt="CSV Import" />

3. Map columns:
   * Column 1: `$distinct_id`
   * Column 2: Your property name

<img src="https://mintlify.s3.us-west-1.amazonaws.com/mixpanel-docs/cohort_csv3.png" alt="CSV Mapping" />

4. Create cohort using the new property

<img src="https://mintlify.s3.us-west-1.amazonaws.com/mixpanel-docs/cohort_csv4.png" alt="CSV Cohort" />

<Warning>
  If a `$distinct_id` doesn't exist, Mixpanel will create a new user profile. CSV cohorts are static and won't update over time.
</Warning>

## Cohort Conditions

Build sophisticated cohorts with multiple condition types:

### Event-Based Conditions

**Basic Event Filters:**

* Users who did \[event] more than X times
* Users who did \[event] in last N days
* Users who did \[event] at least once ever

**Property Filters:**

* Users who did \[event] where \[property] = \[value]
* Users who did \[event] where \[property] > \[number]

**Sequence Filters:**

* Users who did \[event A] and then \[event B]
* Users who did \[event A] but not \[event B]

### Profile-Based Conditions

**User Properties:**

* Users where \[property] equals \[value]
* Users where \[property] is set
* Users where \[property] > \[number]

**Historical Properties:**

With historical properties, specify when the property had a value:

<img src="https://mintlify.s3.us-west-1.amazonaws.com/mixpanel-docs/historical_cohort_1.webp" alt="Historical Cohort 1" />

<img src="https://mintlify.s3.us-west-1.amazonaws.com/mixpanel-docs/historical_cohort_2.webp" alt="Historical Cohort 2" />

**Example:** Users who had "Plan" = "Trial" in the last 30 days

<Note>
  **User Property Behavior**: User properties store only the most recent value. Without historical properties, cohorts use the current value even if it changed over time.
</Note>

### Combining Conditions

**AND Logic:**

* All conditions must be true
* Creates more specific segments
* Example: Premium users AND active in last 7 days

**OR Logic:**

* Any condition can be true
* Creates broader segments
* Example: Watched video OR purchased item

## Using Cohorts in Analysis

### Visualize Cohort Size Over Time

In Insights, select a cohort as a metric:

* See how cohort grows or shrinks
* Track power user population
* Monitor churn cohorts
* Measure acquisition success

**Example:** Track "Active Premium Users" cohort size daily

### Filter by Cohort

Apply cohorts as filters in any report:

* Focus analysis on specific user segment
* Exclude test users or employees
* Analyze beta users separately
* Compare before/after feature access

**Example:** Filter all reports to "New Users" (signed up in last 7 days)

### Compare Cohorts

Breakdown metrics by cohorts:

* Power Users vs Casual Users engagement
* Free vs Premium conversion rates
* iOS vs Android retention
* Geographic segment performance

**Example:** Compare retention for "Organic" vs "Paid" acquisition cohorts

<Note>
  **Multiple Cohort Breakdown**: When breaking down by cohorts, each event is evaluated independently. An event can contribute to multiple cohort buckets if the user belongs to multiple cohorts.
</Note>

## How Cohorts are Computed

Cohorts are computed dynamically when you use them:

**Process:**

1. Run query to compute current cohort membership
2. Run analysis query filtering to those users

**Implications:**

* **Always Fresh** - Cohort membership updates with new data
* **Point-in-Time** - Uses current membership, not historical
* **Performance** - Large cohorts may slow queries

<Note>
  **New Data Timing**: Newly imported events timestamped more than 30 days ago may take up to 12 hours to appear in cohort analysis.
</Note>

### Cohorts vs Funnels for Sequences

When analyzing event sequences, should you use cohorts or funnels?

**Use Cohorts When:**

* You want current users who did sequence
* Comparing user characteristics
* Using in other reports as a filter

**Use Funnels When:**

* You care about conversion window
* Measuring time to convert
* Tracking conversion rate trends

**Example:**

**Cohort:** Users who watched comedy video AND subscribed (ever)

* Shows users who did both
* No time relationship
* Static snapshot

**Funnel:** Watch comedy video → Subscribe (30-day window)

* Measures conversion rate
* Tracks time to convert
* Dynamic trending

## Managing Cohorts

Access all cohorts in [Lexicon](/docs/data-governance/lexicon) → **Cohorts**

### Sharing Cohorts

**Visibility Options:**

* **Private** - Only you can see it (default)
* **Specific People** - Share with selected teammates
* **Organization** - Everyone in project can use it

**Best Practices:**

* Share core cohorts organization-wide (New Users, Power Users)
* Add clear descriptions for shared cohorts
* Use consistent naming conventions
* Document cohort definitions

<Note>
  **Plan Limits**: Growth and Enterprise plans support unlimited saved cohorts. Free plans can create cohorts but cannot save them.
</Note>

### Exporting Cohorts

**CSV Export:**

* Download user list from Cohort Builder
* Contains user IDs and basic properties
* Use for external analysis

**Cohort Sync:**

* Push to [native destinations](/docs/cohort-sync) (Segment, Braze, etc.)
* Use [webhooks](/docs/cohort-sync/webhooks) for custom destinations
* Automate marketing campaigns
* Sync with ad platforms

### Deleting Cohorts

In Lexicon → Cohorts:

1. Click "..." next to cohort
2. Select **Delete**
3. Confirm deletion

<Warning>
  Deleting a cohort removes it from all reports and boards where it's used.
</Warning>

## Real-World Examples

### Example 1: Power Users

**Definition:**

* Users who used app on 5+ of last 7 days
* AND total sessions > 20
* AND Last seen within 7 days

**Use Cases:**

* Compare power user behavior vs average
* Test new features with engaged users
* Identify behaviors that drive engagement

### Example 2: Churned Users

**Definition:**

* Users who signed up
* AND did NOT use app in last 30 days
* AND last seen between 31-90 days ago

**Use Cases:**

* Re-engagement campaigns
* Win-back messaging
* Churn analysis

### Example 3: High-Value Customers

**Definition:**

* Users where Lifetime Revenue > \$500
* AND Purchase count > 5
* AND Last purchase within 90 days

**Use Cases:**

* VIP treatment programs
* Loyalty rewards
* Cross-sell campaigns

### Example 4: Activation Cohort

**Definition:**

* Users who signed up
* AND completed profile
* AND invited 1+ friends
* AND created first project
* Within 7 days of signup

**Use Cases:**

* Track activation rate trends
* Compare activated vs non-activated retention
* Optimize onboarding flow

### Example 5: Trial Conversion

**Definition:**

* Users where Current Plan = "Trial"
* AND Trial Start Date between -7 and 0 days
* AND did NOT convert to paid

**Use Cases:**

* Trial conversion campaigns
* Identify conversion blockers
* Compare trial behaviors

## Tips for Effective Cohort Usage

<Note>
  **Start with Key Segments**: Define core user segments that matter to your business (New, Active, Power, Churned, etc.)
</Note>

<Note>
  **Use Descriptive Names**: Name cohorts clearly so anyone can understand what they represent ("iOS Users - Last 30 Days" vs "Cohort 1")
</Note>

<Note>
  **Add Descriptions**: Explain the purpose and definition of shared cohorts to ensure consistent usage across your team.
</Note>

<Note>
  **Review Regularly**: Audit cohorts monthly to remove unused ones and update definitions as your product evolves.
</Note>

<Note>
  **Combine with Analysis**: Use cohorts to segment all your reports - insights become much more actionable when segmented.
</Note>

<Note>
  **Track Cohort Size**: Create an Insights report showing cohort sizes over time to monitor segment health.
</Note>

## Common Questions

**Q: Can I create cohorts for users who dropped off in a funnel?**

A: Yes! In a Funnels report, click the drop-off segment and select "View Users" → "Save as Cohort".

**Q: How do I find users who did Event A but NOT Event B?**

A: In the Cohort Builder:

* Add condition: Users who did Event A
* Add condition: Users who did NOT do Event B
* Combine with AND logic

**Q: Why is my cohort size changing?**

A: Cohorts are dynamic and recompute with current data. Use specific date ranges in conditions to create more stable cohorts.

**Q: Can I combine multiple cohorts?**

A: Yes! Create a new cohort with conditions:

* User in Cohort A AND User in Cohort B (intersection)
* User in Cohort A OR User in Cohort B (union)

**Q: How do I exclude a cohort from analysis?**

A: Add a filter: "User NOT in \[Cohort Name]"

## Next Steps

* Use cohorts in [Insights](/reports/insights) for segmented analysis
* Compare cohorts in [Funnels](/reports/funnels)
* Track cohort retention in [Retention](/reports/retention)
* Learn about [Cohort Sync](/docs/cohort-sync) for marketing automation
