Decibel Insight
Knowledgebase

Custom Dimensions

Custom Dimensions are used to store additional information for a visitor, session or pageview within Decibel. Information stored in Custom Dimensions can be demographic (for example gender or age range), product related (for example product codes or order IDs) or customer specific (such as a customer reward program number or tier).

Configuring Custom Dimensions

Custom Dimensions can be created by going to Settings > Custom Dimensions from your Decibel account. Click the Add Custom Dimension button where you will presented with the following screen.

On this screen, enter a Name and an optional Description to explain the purpose of the Custom Dimension to other Decibel users.

You will then need to select the appropriate Type for the data you wish to store in the Custom Dimension:

Now select the appropriate Scope for the Custom Dimension:

Followed by selecting the Integration method for Custom Dimension data retrieval:

Once happy, click Save Custom Dimension.

Triggering Custom Dimensions

As mentioned above, if you select Load from JavaScript Variable or Retrieve from URL parameter, you simply need to add the relevant information into the text box.

However, if the selected Integration method for a Custom Dimension is “Decibel JavaScript API Call”, the correct JavaScript code must be added to the website.

You can find the relevant custom dimension code for any custom dimensions that you have created by going to Settings > Custom Dimensions and clicking the Show integration code button (below).

The following example shows a Custom Dimension value being sent when a particular element on the page is clicked:

<script type="text/javascript">
   var buttonEl = document.quereySelector('#addToBasket');
   buttonEl.addEventListener('click', function () {
      var totalEl = document.querySelector('#total');
      decibelInsight('sendCustomDimension', 'Basket Value', totalEl.innerText);
   });
</script>

The sendCustomDimension end-point sends Custom Dimension data to Decibel. The second parameter is the Custom Dimension name and the third parameter contains the value of the custom dimension to be set.

Using Custom Dimensions

Once created, you can use Custom Dimensions as Filters in Segments, while you can also search for sessions that match with Custom Dimension data, such as Order IDs.

In the Sessions Dashboard, using the Filters button, you will be presented with the following screen (below). From the drop-down list next to Search, select the Custom Dimension name that you want to search data for, before using the search text box to type in your query. Click Apply changes to see the results.

Editing Custom Dimensions

To edit a Custom Dimension, simply click the Edit icon next to the relevant custom dimension (above), where you will presented with the same option as when you were creating the custom dimension.

Deleting Custom Dimensions

To delete a custom dimension, simply click the Delete icon (above) on the Custom Dimensions dashboard next to the relevant custom dimension that you want to delete.