Custom dimensions let you collect custom information about your visitors and then use these values in your custom segments.
Collecting custom dimension values
Custom dimension values are being collected using a simple Javascript function which you can call whenever a certain criterion is met. E.q a visitor logs in.
To send a dimension value, use the function below:
window._rd_queue = window._rd_queue || []; window._rd_queue.push(['dimension', DIMENSION_NO, VALUE]);
where you change DIMENSION_NO
and VALUE
with actual values. For example:
window._rd_queue = window._rd_queue || []; window._rd_queue.push(['dimension', 1, 'logged in']);
PS! Right now the number of custom dimensions is limited to 5!
Using custom dimensions in segments
Using custom dimension values in your custom segments is rather straightforward, here’s what you need to know.
- Choose Custom Segments
- Give your custom segment a name
- In “Segment rules” choose Custom Dimension
- Choose the custom dimension number
- Choose matching rule (e.g. Is Equal) and type the value
A segment for logged in users would look like this: