# Mixpanel Cohorts Source

## Source Info

* The Mixpanel Cohorts Source is an **Event Cloud** source. This means that it sends data as events, which are behaviors or occurrences tied to a user and a point in time. Data from these sources can be loaded into your Segment warehouses, and **also** sent to Segment streaming destinations. [Learn more about cloud sources.](/docs/segment/connections/sources#cloud-app-sources)

[Mixpanel Cohorts](https://help.mixpanel.com/hc/en-us/articles/115005708186-Cohorts-Overview-) are groups of users defined by a set of criteria. The Mixpanel Cohorts Source allows you to export Cohorts of users from Mixpanel to Segment so that you can better target users across many downstream connections. You can sync Cohorts of users to your Segment-connected raw data warehouses and downstream destinations that accept Segment identify events.

This source is maintained by Mixpanel. For any issues with the source, contact the [Mixpanel Support team](https://help.mixpanel.com/hc/en-us/requests/new).

## Getting Started

1. From your workspace's [Sources catalog page](https://app.segment.com/goto-my-workspace/sources/catalog) click **Add Source**.
2. Search for **Mixpanel Cohorts** in the Sources Catalog and click **Add Source**.
3. On the next screen, give the source a nickname and configure any other settings.
4. From the new Source's Overview page, copy the Segment write key.
5. Open Mixpanel, navigate to the Integrations page, and paste your write key under the Connect Your Segment Workspace section in the **API KEY** field. Enter a name for your connection in the **CONNECTOR NAME** field.

   ![The Set up Segment form for a Mixpanel project with fields for Connector name, User ID property, Segment Region, and API key.](https://docs-resources.prod.twilio.com/ea08098e59d98097070d9dac31eb0f0cb3ce1b354ab128dfd77210f63f737f6e.png)
6. Once connected, open the Cohorts page and export any cohort to the connection you created in the last step.

   ![Cohort list in Mixpanel with export options.](https://docs-resources.prod.twilio.com/081a50a5b3475f7f781ed4bd62e0d110572f6bc937e2a42b98aa6b14b5890302.png)
7. Once configured, Cohorts sync to Segment based on the sync schedule set in Mixpanel. For more information, see [Mixpanel's Segment Integration documentation.](https://help.mixpanel.com/hc/en-us/articles/4408988683156-Segment-Integration)

## The Cohort sync process

Mixpanel sets a property on the user's profile in Segment indicating whether they are currently part of the cohort.

Mixpanel sends the following Identify call to Segment when a user enters the cohort:

```json
{
  "type": "identify",
  "traits": {
    "Mixpanel - <Cohort Name in Mixpanel>": true,
  },
  "userId": "user@email.com" // mixpanel uses the distinct_id property here
}
```

Mixpanel sends the following Identify call when a user exits the cohort:

```json
{
  "type": "identify",
  "traits": {
    "Mixpanel - <Cohort Name in Mixpanel>": false,
  },
  "userId": "user@email.com" // mixpanel uses the distinct_id property here
}
```

### Sync Mixpanel Cohorts with Engage

To send your Cohorts data to Engage, connect a Mixpanel Cohorts source in the Unify settings.

To connect Mixpanel Cohorts:

1. Navigate to **Unify > Unify settings** and select the **Profile sources** tab.
2. Click **Connect source** to open the Connect sources window.
3. Select **Replay data** to replay the last month of data into Engage.
4. Locate Mixpanel Cohorts and click **Connect source**.

Mixpanel Cohorts data will begin to flow into Engage.
