Send Events to Google Analytics from Sparkforge Workflows
The Google Analytics workflow action sends a custom event into GA4 or Universal Analytics. Configure the Measurement ID, Event Name, API Secret, and an optional Event Value, and the workflow fires the event when the step runs.
The Google Analytics action sends custom events from a workflow into your GA4 or Universal Analytics property. Use it to record offline or downstream conversions, like form submissions, that started on a page outside Google's default tracking.
How to configure
- Action Name: something like "GA4 Form Submission Event."
- Action Type: Google Analytics 4 or Universal Analytics.
- Measurement ID: the ID for the target GA4 property.
- Event Name: the name that will appear in GA reports (e.g.,
purchase,page_view). Follow Google's naming rules. - API Secret: the secret generated in your GA4 setup, used to authenticate the request.
- Event Value: optional numeric value (such as revenue) to attach to the event.
Field reference
| Field | Description | Required |
|---|---|---|
| Measurement ID | Unique ID for the GA4 property. | Yes |
| Event Name | Name of the event in GA4 or UA. | Yes |
| API Secret | Secret key from GA4 used to authorize the event payload. | Yes |
| Event Value | Optional value associated with the event. | No |
Example
Track when a contact completes a form by firing a form_submitted event into GA4. The Measurement ID points at the right property and the API Secret authorizes the request.
Useful triggers
- Form Submission - fire on every submit.
- Page Visit - mark a key page like a pricing or product page.
- Tag Added - record a CRM event such as a lead becoming qualified.
- Appointment Booked - count completed bookings.
- Product Purchase - send purchase value into GA for revenue reporting.
Notes
- Set up the Measurement ID and API Secret correctly before publishing - bad credentials silently fail.
- Events feed into GA reports, audiences, and downstream marketing automations.
- For ad attribution back to Google Ads, use the Add to Google Ads action instead - GA events are not ad conversions.
Frequently Asked Questions
Does this action support GA4 and Universal Analytics?
Yes. Pick GA4 or UA when you set the Action Type and supply the matching credentials.
Where do I find the API Secret?
Generate it in the GA4 admin under Data Streams > the relevant stream > Measurement Protocol API secrets.
Can this fire ad conversion events?
No. GA events feed Google Analytics, not Google Ads conversions. Use the Add to Google Ads action when you need ad attribution.
What happens if the Measurement ID is wrong?
GA silently rejects the event. Verify the ID matches the property and that the API Secret was generated for that same data stream.
Was this article helpful?
Thanks for the feedback.