Landbot and Google Analytics

UTM parameters

To transfer UTM information from the URL to Pardot please follow these steps:

  1. Go to Settings and add utm_source, utm_medium and utm_campaign as hidden fields.
  2. Go to Build and edit the Webhook element
    Add the utm_* keys and assign the variables to the value field.
  3. Please also check the form handler in Pardot and add the utm_* fields if they are missing.
Currently only UTM parameters from the URL are transferred to Pardot. If someone leaves the landing page by clicking on a link the information is removed from the URL and the UTM is only available in Google Analytics.

Event tracking

You can add Javascript elements between steps to track events. In this example a script is triggered when some clicks on "Sales" or "Login|Support".

The script for the "Sales" button looks like this:

window.dataLayer = window.dataLayer || [];
dataLayer.push({
'event' : 'GA Tracking',
'eventCategory' : 'landbot',
'eventAction' : 'start chat',
'eventLabel': 'sales',
'eventValue': 0,
'eventNonInteraction': false
});

For instance you could enter the name of the page / screen (start, step2, ...) in the eventAction parameter and use the eventLabel for the button name.

Conversion tracking

To track a conversion (commercial request) in Google Analytics you can use following script:

window.dataLayer = window.dataLayer || [];
dataLayer.push({
'event' : 'GA Tracking',
'eventCategory' : 'commercial-request',
'eventAction' : 'submit',
'eventLabel': 'Name of the Pardot form handler',
'eventValue': 0,
'eventNonInteraction': false
});


How did we do?


MarTech Academy (opens in a new tab)

Powered by HelpDocs (opens in a new tab)