What does this recipe do? Tracks interactions when a website visitor engages with the Tawk.to chat widget and sends them to Google Analytics. Supported actions:
- Chat started
- Chat ended (by a user). Unfortunately, Tawk.to does not allow to track when the support agent ends the conversation
- The pre-chat form is submitted
- Chat form is submitted when a support agent is offline
Important: this solution does not support the interactions within the pop-up chat window (That’s a current limitation of Tawk.to).
INSTRUCTIONS
- Download Container File
Download the container JSON file (right-click on the link and click “Save Link As” or “Save Target As” to save the JSON file to your computer). - Import JSON File into GTM
Log into your own Google Tag Manager container and head to the Admin section of the site. Under Container options, select Import Container. Read this blog post for more details about importing a container file. - Replace the already existing GA Settings Variable with your own
Currently, the GA Event – Scrolling tag is using the GA Settings Variable named {{REPLACE THIS VARIABLE WITH YOUR OWN GA SETTINGS VARIABLE}}. Click that field and pick your already existing GA Settings Variable instead. - Preview & Publish
Use the Preview options to test this container on your own site. Try testing each of the events to make sure they’re working properly. If everything looks good, go ahead and publish!
View all 40+ Google Tag Manager Recipes