# Event tracking

TIP

Event tracking requires a PRO account.

Events allow you to log interactions independently of page load. Events like playing videos, newsletter signups and download counts. There are two ways to trigger events.

In the following example, an event is tracked when a user downloads a menu PDF.

  1. Using HTML data attributes (can be added to any tag)
<a href="menu.pdf" data-cabin-event="Download Menu">Download Menu</a>
  1. Using JavaScript:
cabin.event('Download Menu')

HTML attributes are automatically converted to `click` events.
Last Updated: 10/14/2021, 10:24:46 AM