Track custom events

Use custom events for actions that a page view cannot explain, such as a successful sign-up, download, demo request, or purchase.

Send an event

window.gum.track("signup_complete");

Call the method only after the action succeeds. Choose short, stable names such as signup_complete, demo_requested, download_started, or purchase. Do not use personal data as an event name.

Add context with properties

window.gum.track("demo_requested", { source: "pricing_page", plan: "team" });

Use properties for useful context, such as a button location, selected plan, or content type. Do not send passwords, email addresses, or other sensitive personal information.

Related documentation