Custom Events
Create custom events to track specific interactions
On this page
Custom events are part of the Max plan. On other plans the Custom Events page shows the events you already have, and you can delete them, but adding or editing needs Max.
What Are Custom Events?
While standard events track the buying journey (view, cart, purchase), custom events let you track other important interactions:
- Newsletter signup button clicks
- Video plays
- Download button clicks
- Social media link clicks
- Banner or promotion clicks
- FAQ accordion opens
- Size guide views
These events appear in GA4 alongside your standard ecommerce events.
Creating a Custom Event
- Open the Pasilobus Google Analytics app
- Open Custom Events in the app menu
- Click Add Event
- Configure your event (see options below)
- Click Save
The event is live on your storefront as soon as it is saved. Reload a storefront page to see it. Custom events are sent after Google's tag has loaded, so they reach GA4 like your page views do.
Event Configuration Options
Event Name
The name that appears in GA4 (e.g., newsletter_signup). Use lowercase with underscores.
Event Type
Choose when the event should fire:
| Type | Use Case |
|---|---|
| Page Visit | Track when customers visit specific pages |
| Click | Track button or link clicks |
| Form Submission | Track form completions |
| Scroll Depth | Track when a shopper scrolls past a share of the page. Set Value to the percentage (default 50) |
Category, Action, Label and Value (Optional)
GA4 only needs the event name. Category, Action and Label are sent as event parameters when you fill them in; leave them blank if your reports do not use them. Value is sent as the event's value (for Scroll Depth it is the percentage).
Page Path (Optional)
Limit the event to specific pages. Leave blank to track on all pages.
Wildcard support: Use * to match any characters in the URL path.
| Pattern | Matches |
|---|---|
/collections/* |
Any collection page |
/products/* |
Any product page |
/pages/faq |
Only the FAQ page |
/blogs/*/tagged/* |
Blog posts with specific tags |
Element Selector (for Click and Form events)
Tell the app which element to track using CSS selectors:
| Selector Type | Example | Tracks |
|---|---|---|
| ID | #newsletter-form |
Element with id="newsletter-form" |
| Class | .signup-button |
Elements with class="signup-button" |
| Data attribute | [data-action="subscribe"] |
Elements with that data attribute |
| Tag + class | button.add-to-wishlist |
Button elements with that class |
Tip: Right-click an element in your browser, select "Inspect", and look for unique IDs or classes.
Example: Track Newsletter Signups
- Event Name:
newsletter_signup - Event Type: Click
- Page Path: Leave blank (track on all pages)
- Element Selector:
.newsletter-submit-button
Example: Track Size Guide Views
- Event Name:
size_guide_view - Event Type: Click
- Page Path:
/products/*(only on product pages) - Element Selector:
[data-action="size-guide"]
Testing Custom Events
After creating a custom event:
- Open your store in a new tab
- Navigate to a page where the event should fire
- Perform the action (click the button, visit the page, etc.)
- Check GA4's DebugView (Admin > DebugView) to see the event in real-time
If the event doesn't fire, double-check your element selector and page path match the actual page.
Event Naming Best Practices
- Use lowercase with underscores:
newsletter_signupnotNewsletterSignup - Be descriptive:
video_playis better thanclick1 - Be consistent: Use the same naming pattern across all custom events
- Avoid spaces and special characters
Managing Custom Events
From the Custom Events page, you can:
- Edit: Update the configuration
- Delete: Remove events you no longer need. A deleted event stops firing on your storefront.
There's no limit to the number of custom events you can create.