Level up your analytics game by leveraging the Power of Mouseflow and Mixpanel together!

Use


You can send data from visits captured by Mouseflow to your Mixpanel account as a Profile Property, an Event Property, or BOTH!

Setting the Profile Property will associate specific visits captured by Mouseflow with Profiles available in Mixpanel.

Setting the Event Property will aggregate all Mouseflow Recordings, identified by Session ID, into an Event list that can be used to quickly reference Mouseflow Recordings.

Setup


Profile Property

In this example, we will send the Mouseflow Session ID to your Mixpanel account as a Profile Property.

Here, we are retrieving the Mouseflow Session ID from the browser, storing it as a variable, and passing the value of that variable to Mixpanel by creating a Profile Property called "mouseFlow" and setting the value of that property to the Mouseflow Session ID:

//setting "mouseFlow" as a profile property inside of the function
setTimeout(function(){
function mouseflowit () {
var mfSessionProf = mouseflow.getSessionId(); mixpanel.people.set("mouseFlow", mfSessionProf);
}
}, 4000);

Event Property

In this example, we will send the Mouseflow Session ID to your Mixpanel account as an Event Property.

Here, we are again retrieving the Mouseflow Session ID from the browser, storing it as a variable, and passing the value to Mixpanel. The difference here is we are creating an Event called "SESSIONCAPTURED" with a property called "mouseFlowIt" and setting the value of that property to the Mouseflow Session ID:

//setting event property "mouseFlowit" as an event property to the event "SESSIONCAPTURED"
setTimeout(function(){
function mouseflowevent () {
var mfSessionEv = mouseflow.getSessionId(); mixpanel.track("SESSIONCAPTURED", { "mouseFlowIt": mfSessionEv });
}
}, 4000);


Please note it is crucial to run these scripts after both Mouseflow and Mixpanel have completely loaded. Running these scripts inside of the standard setTimeout function set to 4 seconds should achieve that result in most cases.

Please contact support@mouseflow.com with any questions.

Did this answer your question?