Custom Events

  • Updated

If you want to track custom conversions for your site, you can take advantage of Advanced Analytics custom events. This feature enables you to monitor actions on your website, or any page or subdomain within your main domain.

This article is about Umso Analytics. If you want to track events with a third-party software, you need to use custom code.

For security reasons, you can only send events from the same domain, or a subdomain of your Umso website. If your website is on, you can send events from,,,, .... However you can't send events from or

How to Set Up Event Tracking

Step 1: Add the Script to Your Header

You'll need to add a specific script to the Custom Site Code of your site settings (if you are using the new editor), or under Integrations (header code) if you are using the legacy editor. 

Insert the following script tag:

<!-- The script url with a placeholder -->
<script src="https://[YOUR_DOMAIN_HERE]/s/interactive.js"></script>

If your domain is, the script will look like this:

<!-- The script url if your domain was -->
<script src=""></script>

Be sure to replace "" with your actual domain.

Step 2: Create a Custom Section

Create a custom section in your page to include the tracker handler:

Umso.track('Your Event Name')

This tracker will run as soon as the section gets loaded in your site. If you want to attach your tracker to a custom button. Please see the examples in the end of this article.

Built-in buttons already have tracking enabled without any code needed. Their event name is the text set to the button, for example, if you have a button "Get Started", that will be the event name.

Step 3: View Events on Analytics Page

You can see the tracked events in your analytics page under Conversion Rate by visiting Umso Analytics

To easily find your new events, select 24 Hours in the top right picker.


Examples of Event Tracking

Here's how you can track different actions using HTML and JavaScript.

Custom Button

To attach a tracker to a custom button, you first need to attach an id to your button, and then add an event listener (event listener is needed as we block onclick for safety purposes).

<!-- track a button click -->
<button id="myButton" onclick="">Click Me</button>

document.getElementById('myButton').addEventListener('click', function() {
Umso.track('Your Event Name')


To attach to a form, you can use the onsubmit to attach your tracker

<!-- track a form submission -->
<form onsubmit="Umso.track('form submitted')">
< input type="text">

Page Load 

To track your page load, you can simply add: 

.addEventListener('load', (event) => {
Umso.track('/page1 loaded')


Was this article helpful?