Skip to content

Custom Dimensions

Gamera supports the concept of custom dimensions. A custom dimension is meta data that you would like to associate with a particular visit. For example, you might have some first party data about the food preferences of a current visitor that you would like to track in Gamera analytics (Visitor likes pizza).

Standard Dimensions

Before you add a custom dimension it is important to know that Gamera tracks the following standard dimensions automatically for visitors. You do not need to pass a custom dimension for any of the following types of dimensions:

DimensionDescription
user_languageThe language set in the user's browser.
user_tzThe time zone of the user.
referrer_typeThe type of source that referred the user to the site.
referrer_domainThe domain of the site that referred the user.
pageThe specific web page viewed by the user.
viewport_sizeThe size of the user's viewport (browser window).
device_typeThe type of device used (e.g., desktop, mobile, tablet).
osThe operating system of the user's device.
os_versionThe version of the operating system.
browserThe web browser used by the user.
browser_versionThe version of the web browser.
geo_countryThe country from where the user is accessing the site.
geo_regionThe region within the country from where the user is accessing.
geo_cityThe city from where the user is accessing the site.
geo_zipThe ZIP or postal code of the user’s location.
geo_dmaThe Designated Market Area of the user's location.
utm_campaignThe campaign name from UTM parameters
utm_termThe campaign term from UTM parameters
utm_sourceThe campaign source from UTM parameters
utm_contentThe campaign content from UTM parameters
utm_mediumThe campaign medium from UTM parameters

Tracking Custom Dimensions

If you would like to attach additional dimensions to your visitors not tracked by our standard dimensions you must complete the following two steps:

  1. Adding the custom dimension to the list of allowed dimensions in the Gamera Site Manager and;
  2. Passing the custom dimension from your site by adding some additional javascript to your page.

Adding Custom Dimension to Allowed Dimensions

Gamera will reject all dimensions that are not added by you or your team members to the list of allowed dimensions in the Gamera Site Manager. Please note, each site has its own inclusion list. You can add an approved custom dimension by following these simple steps

  1. In the Gamera Portal click on Site Manager
  2. From the Site Manager click on the Actions Menu of the site you wish to add the dimension to
  3. Select Edit Custom Dimensions from the site Actions Menu

Edit Custom Dimensions

  1. From the Custom Dimensions page, select New Dimension

Add Custom Dimensions

  1. Enter the name of your custom dimensions

Name Custom Dimensions

  1. Click Ok to add the custom dimension

Passing in Custom Dimensions from your Site

In order to consume your new custom dimension, you must pass the dimension along with its value from your site to Gamera using our on page library.

IMPORTANT: Please note that this code should be placed immediately before or after the Gamera javascript library tag. Placing the code too far down in your site's head or body may result in the dimensions not being sent for every user session

javascript
window.gamera = window.gamera || {};
window.gamera.cmd = window.gamera.cmd || [];
window.gamera.cmd.push(function() {
    window.gamera.addDimensions({
        // List your custom dimensions as 
        // key value pairs here
        "favorite_food": "pizza",
        // If your dimension contains 
        // multiple values, separate 
        // them with commas
        "multi-value-dimension": "value1,value2,value3",
        // If your dimension contains
        // a single value, pass it as 
        // a string
        "single-value-dimension": "this-is-a-test-value"
    });
});

Custom Dimension Limitations

The following limits are applied to custom dimensions:

  • You can have at most 50 custom dimensions (keys)
  • There is a 100 character limit per key-value pair (the name and value of the custom dimension combined).
  • Multi dimension values are treated as multiple custom dimensions. For example animal=bird,dog are treated as two custom dimensions, each having their own 100 character limit.

Designed in America 🇺🇸 and Developed in Switzerland 🇨🇭