In Tag Manager, go to Tags › New › Tag Configuration and choose Custom HTML.
Screenshot coming soonGoogle Tag Manager tag types with Custom HTML highlighted
2
Step 2: Paste the Tag Manager version
Paste the code below. It's the same Formleak line, written so Tag Manager keeps your site key. Leave Support document.write unticked.
Paste this version (made for Tag Manager) into a Custom HTML tag.
<script>
(function () {
var s = document.createElement('script');
s.src = 'https://formleak.com/t.js';
s.setAttribute('data-site', 'YOUR_SITE_KEY');
s.defer = true;
document.head.appendChild(s);
})();
</script>
3
Step 3: Fire it on all pages
Under Triggering, choose All Pages (or Initialization - All Pages to load it a little earlier). Name the tag “Formleak” and save.
Screenshot coming soonThe Triggering panel in Tag Manager with All Pages selected
4
Step 4: Test, then publish
Click Preview to check the tag fires, then Submit › Publish so it goes live.
5
Step 5: Check it's working
Open a page on your live site that has a form and click into a field. Then open your website in Formleak: the setup check turns green as soon as data arrives.