Implement DataFast with Google Tag Manager

Use Google Tag Manager (GTM) to easily deploy and manage DataFast analytics across your website without modifying code directly.

Get started with Google Tag Manager

  1. Log in to your Google Tag Manager account
  2. Select your container
  3. Click on Tags > New
  4. Name your tag (e.g., "DataFast Analytics")
  5. Click Tag Configuration and select Custom HTML
  6. Paste the following JavaScript code (not the regular script tag):
<script>
  (function() {
    var script = document.createElement('script');
    script.defer = true;
    script.setAttribute('data-website-id', 'yourwebsiteid');
    script.setAttribute('data-domain', 'yourdomain.com');
    script.src = 'https://datafa.st/js/script.js';
    document.head.appendChild(script);
  })();
</script>

Replace yourwebsiteid and yourdomain.com with your actual values from the DataFast dashboard.

  1. Click Triggering, select All Pages and click Add
  2. Click Save
  3. Click Submit at the top right, then Publish

Troubleshooting

  • If data doesn't appear, check that your tag is firing in GTM's preview mode
  • Verify that your website ID and domain values are correct
  • Ensure the tag isn't being blocked by content security policies (CSP)
  • Make sure your tag is executing early in the page load sequence by setting it to fire at the earliest appropriate event

For advanced GTM configurations or custom event tracking, contact us at marc@datafa.st.

Something missing? Suggest features ✍️