How to use Polygraph with Google Tag Manager (GTM)

January 18, 2023 ∙ 3 minute read

In this article we explain how to use Google Tag Manager (GTM) to add Polygraph to your landing pages.

How to set up and use Polygraph

We previously wrote an article which explained How to set up and use Polygraph. In a nutshell, you only need to do two things:

  1. Add the Polygraph tracking code to the HEAD section of your website.
  2. Ensure your ads are using the UTMs utm_campaign, utm_source, and utm_term. (Not sure what a UTM is? Check out our article What are UTMs and why should they be used?)

If step 1 is a challenge for you, for example, maybe you don't have access to your website's source code, it's possible to use GTM instead.

How to use Polygraph with Google Tag Manager (GTM)

Please follow the steps below to add Polygraph to your landing pages via GTM:

  1. From within GTM click Add a new tag.
  2. Click Tag Configuration and select Custom HTML.
  3. Paste the following in the HTML section:

    <!-- Polygraph fraud detection -->
    <script src="https://cdn.polygraph.net/pg.js"></script>
    <!-- Polygraph fraud detection -->
  4. Click Triggering and choose Initialization - All pages.
  5. Click Save and save it as "Polygraph".
  6. Click Submit.

That's it! GTM has now added Polygraph to your landing pages. (Don't forget to add UTMs to your ads!)

A word of warning

It's better to manually add the Polygraph tracking code to the HEAD section of your website rather than adding it via GTM. There are two reasons for this:

  1. By using GTM to add Polygraph to your website, you're relying on a third party (Google) to ensure Polygraph runs on your landing pages. You can remove this dependency by manually adding the Polygraph tracking code to the HEAD section of your website.
  2. GTM comes with a slight performance cost, so it's better to manually add the Polygraph tracking code to your website to ensure maximum performance.

Conclusion

Adding Polygraph to your website using GTM is easy, but it comes at a cost. If possible, try to manually add the Polygraph tracking code to your website instead.

Try Polygraph today.