---
description: Configuration details for Mixpanel
---

# Mixpanel

## Overview

Via the Mixpanel destination, Hightouch can create and sync users and events.

## Initial Setup

To find the setup keys, navigate to Settings -> Project Settings -> Overview -> Access Keys.

![](https://1454996985-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MHsth_4gateO06TTdt4%2F-MQldEPti6lSWrxqYlBQ%2F-MQldet0ohKMd4T3pmCD%2FPasted_Image_1_11_21__9_32_PM.png?alt=media\&token=98b29d5b-0f1d-46d8-b7ba-d104308b4834)

## Syncing Mixpanel Objects&#x20;

### Sync Modes

This integration only supports the Upsert mode.

In this mode, new users and groups will be inserted into Mixpanel and all attributes will be kept up-to-date within Mixpanel.

This mode is good for the following scenarios:

* You want to push objects into Mixpanel and want to keep the data up-to-date

### Record Matching

Records can be matched from your source to your Mixpanel workspace by your Mixpanel User ID, email or Group ID.

![](https://1454996985-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MHsth_4gateO06TTdt4%2F-M_cuT2yPXI4o94ufLUL%2F-M_cumypKmqjT-j0xh55%2Fimage.png?alt=media\&token=13de1327-cdad-4ff4-9fcf-c56d0b003ded)

### Group Key (Groups Only)

If you are syncing group profiles, you need to set the group key of the type of group. You can find your group keys in Settings > Your Project.



![](https://1454996985-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MHsth_4gateO06TTdt4%2F-M_cuT2yPXI4o94ufLUL%2F-M_cxI1whnx60AWnEcgl%2Fimage.png?alt=media\&token=0f75ab2f-7d1e-4f14-b409-d41810f209e2)

To sync your organization profiles, enter the key `org_id` into the Mixpanel group key field.

![](https://1454996985-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MHsth_4gateO06TTdt4%2F-M_cuT2yPXI4o94ufLUL%2F-M_cyyeI_gCWQWhSftyh%2Fimage.png?alt=media\&token=68bada5a-6f8f-4ce1-a980-fe3cef9bd96f)

### Field Mapping

You can sync columns from your source to Mixpanel's default and custom fields.&#x20;

![](https://1454996985-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MHsth_4gateO06TTdt4%2F-M_cuT2yPXI4o94ufLUL%2F-M_cvG1C9zI2wgqCcR4u%2Fimage.png?alt=media\&token=9dd507b9-1dd3-4d6a-8950-9a65d3f9f0d0)

### Assigning Users to Groups (Users Only)

To assign users to groups, create an upsert sync to users. Then, create a column in your model which contains the group IDs that you want to assign the user to.&#x20;

For example, to sync organizations, use a column called `organizations` containing either a group ID (i.e. `google`) or an array of group IDs (i.e. `[ google, apple, microsoft ]`).&#x20;

Then, [find your group key](#group-key-groups-only), and use it as the destination field to sync to.

![](https://1454996985-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MHsth_4gateO06TTdt4%2F-M_cuT2yPXI4o94ufLUL%2F-M_cyjz_Mkvc63AwlDh-%2Fimage.png?alt=media\&token=34fe7e17-07d8-4aed-80f3-a323ea947e75)

### Users location

By default, users uploaded using Hightouch won't have any location associated. To set a location, provide an IP address (field `$ip`), or longitude and latitude coordinates (fields `$longitude` and `$latitude`). For more information, check [Mixpanel's official documentation](https://help.mixpanel.com/hc/en-us/articles/115004499343-Tracking-Geolocation-with-Server-Side-Implementation). &#x20;

## Syncing Mixpanel Events <a href="#syncing-amplitude-events" id="syncing-amplitude-events"></a>

### Track Event Configuration <a href="#track-event-configuration" id="track-event-configuration"></a>

Hightouch supports sending events of a given name, i.e. `Signed Up`. Hightouch also allows you to choose the column containing the timestamp, user ID, and device ID.

Note: Hightouch accepts a normal date time format for the timestamp, and automatically converts it to the format required by Mixpanel.

![](https://1454996985-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MHsth_4gateO06TTdt4%2F-M_cuT2yPXI4o94ufLUL%2F-M_cw0J-KCWEZeQCn8ql%2Fimage.png?alt=media\&token=5bd27886-5f72-4f42-b4cc-234dd1e3ff4d)

### Field Mappings <a href="#field-mappings" id="field-mappings"></a>

Hightouch allows you to pass data to the event properties of a Mixpanel event.

![](https://1454996985-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MHsth_4gateO06TTdt4%2F-M_cuT2yPXI4o94ufLUL%2F-M_cw9nQ0fN3UV0hFCDT%2Fimage.png?alt=media\&token=af5d2304-491a-40ce-b98c-43d67908637f)

### Assigning Events to Groups

To assign users to groups, create a sync to events. Then, create a column in your model which contains the group IDs that you want to assign the event to, similar to assigning users to groups.

For example, to sync organizations, use a column called `organizations` containing either a group ID (i.e. `google`) or an array of group IDs (i.e. `[ google, apple, microsoft ]`).&#x20;

Then, [find your group key](#group-key-groups-only), and use it as the destination field to sync to.

![](https://1454996985-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MHsth_4gateO06TTdt4%2F-M_cuT2yPXI4o94ufLUL%2F-M_czYAmMJVNyZK-JYMA%2Fimage.png?alt=media\&token=59393fa2-d8f9-40b5-9b7f-fa67a89c8646)
