Switching from Fathom
Swap the tag, carry your events and goals across, and bring the site’s history with it.
Add the tag
Add the site, then put fivebar’s tag in the <head> of
every page, beside Fathom’s:
<script async data-domain="example.com" src="https://fiveb.ar/js/tally.js"></script>Where Fathom’s tag names the site by its ID, fivebar’s names it by its domain. Run both for a few weeks to compare the same days, then remove Fathom’s tag.
A single-page app needs nothing like Fathom’s data-spa: fivebar counts each page it moves to. Links
to other sites, downloads and forms sent are counted with the tag alone, as
actions. Addresses you blocked in Fathom go under
Excluded traffic in the site’s settings.
Events and goals
Each fathom.trackEvent() call becomes a tally() call with
the same name:
| Fathom | fivebar |
|---|---|
fathom.trackEvent('Signup') | tally('Signup') |
fathom.trackEvent('Purchase', { _value: 1999 }) | tally('Purchase', { revenue: 19.99, currency: 'GBP' }) |
fathom.trackGoal('ABCD1234', 0) | tally('Signup'), named for what it counts |
Fathom’s _value is in cents. fivebar’s
revenue is the amount itself, with its currency beside it.
Every event is a goal already, so there’s nothing to set up for them. To count the visits that reach a page, such
as /thanks, add a page goal in the site’s settings, with
* for anything.
Bring the history over
Once fivebar is counting, choose Import from Fathom under Import in the site’s settings, with an API token and the site’s ID. The dashboard then reaches back before fivebar’s first day: see Importing from Fathom.