Skip to content
  • There are no suggestions because the search field is empty.

Tracking Bookings and Form Submissions in Your Own Analytics (Google, Meta, Etc)

When a visitor books a session or submits a website form, Gymdesk sends a conversion event to the page. Add a short listener to your site, and your own tags (Google Ads, Meta Pixel, or Google Tag Manager) record the conversion.

The listener runs on your own page, so your tags keep their cookies and their click IDs (gclid, fbclid). The event holds no personal data.

In this article

  • The conversion event
  • Where to add the listener
  • Google Ads
  • Meta Pixel
  • Google Tag Manager
  • Find your form value
  • Remove your old conversion snippet


The conversion event

Gymdesk dispatches a gymdesk:conversion event on window after each successful booking or form submit. The event detail holds three values:

Value What it holds Example
kind booking for a booking, form for a website form booking
gym Your gym reference. It is the attr-gym value in your embed codes. g65dD
form The booking form or website form reference. It is the attr-form or attr-ref value in your embed code, if your embed code has one; otherwise see Find your form value. It is null when no booking form applies. 1zX1X

These pages send the event:

  • The booking widget, the schedule widget, the booking page, and the schedule page.
  • Website forms: popup forms, bottom bar forms, form blocks on your website pages, embedded forms, and the contact page.

Good to know:

  • A visitor who joins a waitlist also sends a booking event. The event does not tell a waitlist join from a booking.
  • The member sign-up form does not send the event.
  • Bookings that staff make in Gymdesk do not send the event.

Where to add the listener

Add the listener on the page that shows the widget or the form, after the code that loads your tags.

  • Gymdesk website: Go to Website, then Settings. Paste the listener in Tracking and Analytics > <head> Scripts, below your tag code. Click Save Settings.
  • Your own website: Paste the listener on each page that holds a Gymdesk widget or form, below your tag code.

Google Ads

Replace AW-XXXXXXXXX/XXXXXXXXXXXXXXXX with the conversion ID and label from your Google Ads conversion action. This example tracks bookings. To track website forms, change booking to form.

<script>   window.addEventListener('gymdesk:conversion', function (event) {     if (event.detail.kind === 'booking') {       gtag('event', 'conversion', { send_to: 'AW-XXXXXXXXX/XXXXXXXXXXXXXXXX' });     }   }); </script>

Meta Pixel

This example tracks both: Lead for a website form and Schedule for a booking. To track only one, remove the other if block.

<script>   window.addEventListener('gymdesk:conversion', function (event) {     if (event.detail.kind === 'form') {       fbq('track', 'Lead');     }     if (event.detail.kind === 'booking') {       fbq('track', 'Schedule');     }   }); </script>

Google Tag Manager

The listener pushes the event to the data layer. In Google Tag Manager, make a Custom Event trigger with the event name gymdesk_conversion. Then attach your tags to that trigger.

<script>   window.addEventListener('gymdesk:conversion', function (event) {     window.dataLayer = window.dataLayer || [];     window.dataLayer.push({       event: 'gymdesk_conversion',       gymdesk_kind: event.detail.kind,       gymdesk_form: event.detail.form     });   }); </script>

The listener pushes both bookings and website forms. To fire a tag for one of them only, add a trigger condition on gymdesk_kind (booking or form). To use gymdesk_kind or gymdesk_form in a trigger condition, make a Data Layer Variable for each one.

Find your form value

To track one form only, compare event.detail.form with that form's value:

if (event.detail.kind === 'booking' && event.detail.form === '1zX1X') {   // your tag }

To see the value, add this listener, open your browser's developer console, and make a test booking or submit:

<script>   window.addEventListener('gymdesk:conversion', function (event) {     console.log(event.detail);   }); </script>

Remove your old conversion snippet

Important: If your booking form or website form has a conversion snippet that calls the same tag, remove the snippet when you add the listener. If you keep both, the conversion counts twice.