Install with Google Tag Manager
Add Loomduct to a site through Google Tag Manager.
Add the Loomduct script with a Custom HTML tag that fires on every page.
Before you start
- The Loomduct snippet with your project token. Copy it from Install with the script tag and replace
lmt_your_project_tokenwith your token. - Google Tag Manager already installed on your site.
Steps
Create a Custom HTML tag
In your Tag Manager container, select Tags → New. Under Tag Configuration, choose Custom HTML and paste the Loomduct snippet into the HTML field.
Fire it on all pages
Under Triggering, add the All Pages trigger. Name the tag, for example "Loomduct", and save it.
Publish the container
Select Submit and publish the new version of your container.
Google's own guide: Custom tags.
The SDK tracks page changes in single-page apps on its own. Do not add a second tag for history changes, or page views are counted twice.
Check that it worked
- Open your live site in a new tab.
- Open your project in the Loomduct dashboard. Your visit shows up as online now on the Overview within a few seconds.
If nothing shows up, see Install with the script tag.