Storing data about your users with super properties

This is an advanced guide. It assumes that you understand the concept of 'properties'.

Unfortunately Super Properties are not available for Facebook due to limitations of the platform. Super properties use cookies and thus cannot be used in FBJS. Iframe apps are effected as well as some browsers reject cookies from iframes.

Super properties are global properties that get attached to everything you are tracking. If you find it tedious to continuously attach a gender property of a user to every event, this is for you.

Some examples of these are:

  • User type (free/paid?)
  • Account age
  • Gender
  • Ad-campaign

By registering these as super properties, you will be able to segment each event by any of them without specifically including them as event properties every time.

Registering super properties to a user is very simple. By default, super properties are included with all events and funnels, but it is possible to only include them with events or only with funnels.

Here's a breakdown of the function and its parameters. We'll show an example implementation in a moment.

Now for an example implementation. There are a couple of places it makes sense to register super properties: on page load, if you have the data about your users already, and at the time of an individual event if that event tells you more about them.

If I want to register super properties on page load, it will look something like this:

If I want to register the super property after an event has occurred, it's just as easy. Let's say that the user just signed up for an account and I want to tag them with their account type.

Then, when I log an event or funnel these super properties will be automatically included. If I were to call

it would actually be sent to the server as

This allows you to segment the 'button click' event by user type, gender, and account type with no extra effort. Using super properties drastically simplifies the rest of the integration process.

Using our javascript library, super properties only have to be registered at least once per visitor as we will persist the super properties across page loads later using cookies.

Super properties and events

If you want certain super properties to only show up for events, and not funnels, you just register them with the "events" type.

For this example, the 'account type' and 'ad' super properties would be passed along with normal events, but not with your funnels.

Super properties and funnel analysis

Super properties let you register properties (such as referrer or ad campaign) once at the beginning of your funnel, but see them for every step.

If you want certain super properties to only show up for funnels, and not all events, just register them with the "funnels" type. Otherwise, it will default to adding them to both events and funnels.

In this example, the 'ad campaign' super property would only be sent with funnel events.

Thanks to GitHub for the gists