Sub topic 2
Event Parameters: Describing What Happened
Assume you understand GA4 events and have basic experience with gtag.js or Google Tag Manager. This chapter focuses on event parameters: the extra values attached to an event that explain its context.
What an event parameter is
An event parameter is a key-value pair that describes an event. The key names the detail, and the value supplies the detail.
For example, select_plan says that a visitor selected a plan. Parameters can tell you which plan and billing period were selected:
gtag('event', 'select_plan', {
plan_tier: 'pro',
billing_cycle: 'annual'
});This event contains:
| Part | Example | Meaning |
|---|---|---|
| Event name | `select_plan` | What happened |
| Parameter name | `plan_tier` | Which detail is being described |
| Parameter value | `pro` | The value of that detail |
Parameter names should describe facts about the event. Use plan_tier for a plan category, not a vague name such as value1.
How parameters fit the GA4 data model
GA4 stores each event separately. Parameters belong to the event that carries them. They do not automatically become permanent properties of the user.
If the same visitor later triggers another event, that event only contains these parameters if your implementation sends them again. Use user properties when a value should describe the user across later events, such as a customer type.
Standard and custom parameters
GA4 has recommended events with documented parameter names. For example, a purchase event commonly includes transaction_id, value, and currency. Using documented names helps GA4 and connected products interpret the data correctly.
A custom parameter is a parameter that you define for your own business needs. plan_tier and billing_cycle are custom parameters in the example.
A custom parameter can be collected without immediately appearing as a usable report dimension. To analyze it in standard reports or Explorations, register it as an event-scoped custom dimension in Admin. To analyze a numeric value, register it as a custom metric when that is the appropriate definition.
Design parameters that answer questions
Start with the question you want to answer, then choose parameters that provide the needed context.
For a video event, useful parameters might include:
video_title, a descriptive text valuevideo_provider, such asyoutubevideo_length_seconds, a numeric valuevideo_position_seconds, a numeric value showing progress
Keep one meaning per parameter. Do not send a mixture of text and numbers under the same name. For example, always send video_length_seconds as a number, not sometimes as 184 and sometimes as "three minutes".
Avoid putting several facts into one value such as pro_annual_green. Separate values are easier to filter, compare, and reuse.
Common errors
A parameter may be missing or unusable when:
- The tag sends a different name, such as
planTierinstead ofplan_tier. - The value is sent as text when analysis expects a number.
- The parameter is attached to the wrong event.
- The implementation sends an empty value.
- A custom parameter is collected but never registered as a custom definition.
- A parameter contains personal information, such as an email address or full name.
Check the outgoing event in DebugView before registering a custom definition. Registration does not repair incorrectly sent data, and it does not change historical events.
Exercise
You need to analyze which subscription plan visitors choose and whether they pay monthly or annually. Which event name and parameters would you send?
Show answer
Send an event such as select_plan with separate parameters such as plan_tier: 'pro' and billing_cycle: 'annual'. Register those parameters as event-scoped custom dimensions after validating them in DebugView.