Skip to main content
Support home / Event conversions

Creating and using events

Note: As of Oct 25, 2023, we no longer support `trackGoal` for new goals/events. If you’re using `trackGoal` currently, it’ll continue to work, but the new way of doing events is below.

Events (also called goals or conversions) allow you to track actions that visitors take on your site. For example, button clicks, form submissions, newsletter sign-ups, and even e-commerce conversions like starting a free trial or buying a product could all be events you create.

Events currently include one required variable (the event name) and then support 3 optional parameters

  1. Required: the event name (set in code on your site; see below examples)
  2. Optional: options object (supported values are _site_id and _value)

Always make sure that you add the event code after your embed code. We also do not track events locally, as they require https/http to function.

You also cannot rename an event once it’s been created and fired off to your dashboard but you can easily change the event name you're sending us from your code.

Here's how to track various events and conversions in Fathom

Watch a video tutorial on simple events.

Allowed event names

You can name your event any name you want, but avoid special characters and emojis. Event names can be anything, but most importantly, they need to be something you (and your team) can easily and instantly recognize - so you know what each event conversion means.

Example code for events

Here’s an example of how events are programmed into your site:

fathom.trackEvent('cart add', {
_value: 100, // Value in cents
});

Here’s an example of a simple event without a value or overriding Site ID:

fathom.trackEvent('newsletter signup');

Deleting and blocking events

If you need to delete a specific event, you have a couple of options:

  • Delete: Simply delete the event and its data.
  • Delete and block: Delete the event data and prevent data being collected for the event in the future. You can unblock the event at any time, but this will not restore the deleted data.

To find these options, go to your dashboard and scroll down to the Events box. Click the Manage events button to open the Event settings page. Find the event in the list, click the ellipsis button next to its name, and select either Delete or Delete and block.

If you've blocked an event and want to unblock it, go to the Blocked Events section at the bottom of the Event settings page, where you'll find the option to unblock it.

Using events with GTM (Google Tag Manager)

If you're looking for ways to use Fathom events in GTM, take a look at our tailored examples for GTM in our GTM documentation.


If you still have questions or require help with anything, please reach out to us and we'll happily get things sorted out for you.


Can't find what you're looking for?