Sub topic 3
Registering custom dimensions so you can filter on them
This chapter assumes you already have a working GA4 property and know what events, event parameters, and user properties are. You also need Editor or Administrator access, because registering a custom dimension is a property configuration change. Here you will learn why GA4 collects parameters that you cannot yet filter on, and how to register them so the audience builder can use them.
Why collected data is not automatically usable
GA4 stores every parameter you send with an event. Only some of that data appears as a dimension in the interface. Standard parameters such as currency, value, and item_id are already mapped to built-in dimensions. A parameter you invent yourself, such as plan_name, is stored in the raw event but has no dimension attached to it.
Until you register it, a custom parameter has these limits:
- It does not appear as a filter option in the audience builder.
- It does not appear as a dimension in standard reports or Explorations.
- It is still present in the BigQuery export if you have linked one, so the data is not lost.
Registering a custom dimension tells GA4 to expose a parameter or user property under a name you choose. It does not change what your site sends.
The three scopes
When you create a custom dimension, you choose a scope. The scope decides which kind of data the dimension reads and how it behaves.
| Scope | Reads from | Value applies to | Typical example |
|---|---|---|---|
| Event | An event parameter | The single event that carried it | `plan_name` on `select_plan` |
| User | A user property | The user, until you change it | `membership_tier` |
| Item | An item parameter in the `items` array | One item in an ecommerce event | `item_color` |
The scope must match how you collect the data. An event parameter cannot be registered with user scope, and a user property cannot be registered with event scope.
For audiences, the choice has a practical effect. A user-scoped dimension describes the person, so it suits conditions such as "membership tier equals premium". An event-scoped dimension describes one action, so it suits conditions such as "selected plan equals pro". The scope you pick in the audience builder for the condition, covered in a later chapter, then decides whether the match must happen in the same event, the same session, or any session.
Registering an event-scoped dimension
Start with the code that collects the parameter. This is the custom event from the plan.
gtag('event', 'select_plan', {
plan_name: 'pro',
billing_period: 'annual'
});Two parameters are sent: plan_name and billing_period. To filter on plan_name, register it:
- Open Admin and choose your property.
- Under Data display, open Custom definitions.
- On the Custom dimensions tab, select Create custom dimension.
- Enter a Dimension name. This is the label people will see in the interface, for example
Plan name. - Set Scope to Event.
- Choose the Event parameter from the dropdown. If
plan_namehas been collected recently, it appears in the list. Otherwise type it exactly as it is sent. - Optionally add a description, then select Save.
The dimension name and the parameter name are separate. You can display Plan name while the parameter stays plan_name. The parameter name must match exactly, including case and underscores. Plan_Name and plan_name are different parameters.
Registering a user-scoped dimension
User properties work the same way, but you set them with a different call.
gtag('set', 'user_properties', {
membership_tier: 'premium'
});Register it with Scope set to User and the User property set to membership_tier. Once registered, you can build an audience of users where Membership tier equals premium.
User properties persist. GA4 attaches the latest value to later events from that user, so you do not need to resend the property on every event. If a user upgrades from basic to premium, set the property again with the new value, and subsequent events carry the new value.
Timing: registration is not retroactive
Registration only applies to data collected after you save the dimension. Historical events for that parameter do not fill in. Two practical effects follow:
- A new dimension can take up to 24 hours to start populating in reports and Explorations.
- An audience that filters on the dimension only counts users whose matching events arrive after registration. Users who triggered the event last week are not included.
For this reason, register dimensions when you plan your tracking, not when you build the audience. If you add the select_plan event in January and register plan_name in March, an audience on plan_name has no members from before March.
Limits and naming rules
Each property has a fixed quota of custom definitions. For a standard property, the documented limits are 50 event-scoped dimensions, 25 user-scoped dimensions, and 10 item-scoped dimensions. GA4 360 properties have higher limits. Check the current Google documentation, because quotas change.
These limits shape how you design tracking:
- Archiving a dimension does not always free quota immediately, so avoid registering dimensions you may not need.
- Do not register parameters with very many unique values, such as a timestamp or a session ID. These count against a high-cardinality limit in reports, and they are rarely useful for audience conditions.
- Reuse a small set of parameters across events. A single
plan_nameparameter registered once works for every event that sends it.
Parameter names also have rules. Names must start with a letter, can include only letters, numbers, and underscores, and are limited in length. Values have a length limit too, and longer values are truncated. Avoid sending personally identifiable information, such as email addresses, in any parameter. Google's policies prohibit it, and a registered dimension would expose it in reports.
Common errors
| Symptom | Likely cause | Fix |
|---|---|---|
| The parameter is missing from the dropdown | No recent events carried it | Send the event, wait for processing, or type the name manually |
| Dimension shows `(not set)` | Wrong scope, misspelled parameter, or the event was sent before registration | Check the scope and spelling, then test with new traffic |
| Audience builder cannot filter on the parameter | The dimension is not registered, or you are in the wrong scope | Register it with the matching scope |
| User dimension values look stale | The property was set once and never updated | Call `set user_properties` again when the value changes |
| Quota reached | Too many dimensions registered | Archive unused ones or reuse existing parameters |
You can confirm that a parameter is arriving before you register it. In Admin, open DebugView with debug mode on and select the event. The parameter should appear in the event's parameter list with the value you expect. If it does not appear there, no registration will fix the problem.
Checking your work
After registration and a day of fresh traffic, confirm the dimension works:
- Open Explore and create a free-form exploration.
- Add your new custom dimension and a metric such as Event count.
- Check that real values appear, such as
pro, rather than only(not set). - Open the audience builder and confirm the dimension appears when you add a parameter filter.
Exercise
You send gtag('event', 'select_plan', { plan_name: 'pro' }) and want an audience of users who selected the pro plan. In the audience builder, plan_name is not offered as a filter. What two things should you check first, and which scope should the dimension have?
Show answer
Check that you registered plan_name as a custom dimension, and that events with the exact parameter name were sent after registration (confirm in DebugView). The scope should be Event, because plan_name is an event parameter. A user property would need User scope instead.
Exercise
You registered a custom dimension in March, but your tracking code has sent plan_name since January. Can an audience on plan_name include users who selected a plan in February? Explain why.
Show answer
No. Registration is not retroactive, so only events collected after registration can be filtered on. Users who selected a plan in February are included only if they trigger a matching event again after the dimension was saved.