Connect Mixpanel¶
Connecting Mixpanel gives Squoosh a source to calibrate your synthetic shoppers against. Squoosh reads your recorded event traffic and shapes the shopper pool to match your real visitors, so experiment results reflect your actual audience. This page covers what the connection does and how to set it up from the Integrations page.
Beta
Mixpanel is a newly added connector. It calibrates device, geography, and traffic-source mix, plus a conversion rate when you set a conversion event. Mixpanel has no native "device type" or "session" concept, so two things work a little differently here than with Google Analytics — see Limits and caveats.
Provider API note
Squoosh reads this data through Mixpanel's Segmentation Query API, which Mixpanel has placed in maintenance mode: their own reference recommends discontinuing new use of it in favor of building an Insights report and querying it via their newer Insights Query API. Squoosh's connector still works today and this is being tracked as a planned migration, not an outage — nothing you need to do differently, but worth knowing if Mixpanel ever deprecates the endpoint outright.
What the connection does¶
Mixpanel is a calibration source. Once connected, Squoosh reads your event data and builds synthetic shoppers whose mix of device, traffic source, and geography matches your real visitors — the same role Google Analytics or Shopify Analytics plays. Setting a conversion event also gives Squoosh a conversion rate to ground shopper behavior against.
The connection is not required to run a test — Squoosh can build a pool from a general e-commerce mix without it. For how the calibrated pool behaves and how the match is measured, see Synthetic shoppers.
Connect Mixpanel¶
You'll need a service account (Mixpanel's organization-level API credential, not your personal login) and the project's numeric ID.
- In the sidebar, click Integrations.
- In the Mixpanel row, click Connect.
- Enter:
- Service account username — from your Mixpanel organization's service accounts.
- Service account secret — kept private; Squoosh never shows it again after you save it.
- Project ID — the numeric ID of the project to read from.
- Region (optional) —
us,eu, orin(Mixpanel's three data-residency regions). Defaults tous. - Base event (sessions proxy) (optional) — the event Squoosh treats as a pageview-equivalent for the device/geography/channel breakdowns. Defaults to Mixpanel's autocapture pageview event (
$mp_web_page_view) if left blank. - Conversion event (optional) — the event name Mixpanel logs for a purchase or signup. Leave it blank if you don't want a conversion rate calibrated from Mixpanel.
- Click Connect.
Squoosh verifies the credentials live before saving. The row shows Connected — syncing while the first calibration read runs, then Calibrating shoppers from Mixpanel once real data is grounding your shopper pool.
What it grounds¶
| Dimension | Source | Notes |
|---|---|---|
| Device | Operating-system property ($os) |
Mixpanel has no native device-category field, so Squoosh infers mobile/desktop/tablet from the OS. An OS it doesn't recognize is dropped, never guessed. |
| Geography | mp_country_code |
|
| Traffic source | $initial_referring_domain |
Mixpanel reports the literal value $direct (not a blank value) for a visitor with no referrer; Squoosh reads that value correctly as Direct traffic. |
| Conversion rate | Your base event's total vs. your conversion event's total | Reported as an event-count rate, not a session rate — Mixpanel has no native session concept. |
A dimension needs a reasonable amount of traffic before Squoosh treats it as real signal — a handful of events doesn't become a fabricated distribution. Below that floor, Squoosh leaves the dimension out of calibration rather than guessing.
Limits and caveats¶
- Device mix is inferred, not native. Mixpanel doesn't track a device-type property directly, so Squoosh derives mobile/desktop/tablet from the operating system. This is disclosed on the connection's detail view.
- Conversion rate is event-based, not session-based. Because Mixpanel has no session concept, the rate compares total event counts rather than true sessions.
- No conversion event configured means no conversion rate. Squoosh never invents one.
- Underlying Mixpanel API is in maintenance mode. See the note above — Squoosh is tracking a future migration to Mixpanel's Insights Query API; this doesn't affect the connection today.
Troubleshooting¶
| Problem | What to do |
|---|---|
| Connection fails immediately | Confirm the service account username/secret pair is still active in Mixpanel and that the project ID and region match. |
| "Missing Mixpanel project ID" | Project ID is required — reopen Connect and fill it in. |
| No conversion rate shows up | The Conversion event field is optional — add the exact event name Mixpanel logs for a purchase to get one. |
Related¶
- Synthetic shoppers — how the calibrated pool behaves and how the match is read.
- Connect Google Analytics and Connect Shopify — the original calibration sources.
- Connect a CSV import — an alternative if you'd rather export numbers from another tool.