Google Tag Manager can make it easy for you to install and manage snippets of code and HTML in your website and as such it can be used to help you install Viral Loops too.

This guide is relevant to these templates:

  • Refer a Friend
  • Milestone Referral
  • Tempting Giveaway
  • Leaderboard Giveaway
  • Startup Pre-launch
  • Online to Offline 


To install the Viral Loops snippet in your page, create a new tag in your GTM container and choose the "Custom HTML" type. 

In it, paste your campaign snippet which you can find at the Installation step of the Campaign Wizard:

Then, choose the trigger for this tag. It should be "Window Loaded": 

If you don't have this trigger available, go to "Triggers" and create it by clicking the "New" button:

Now save and publish your container.

If you are using the In-app Referral widget of the Refer a Friend or Online to Offline templates, you're ready to go, there's nothing else you need to do to get the campaign live.

For any other template or if you're using the Form Widget for Refer a Friend, you still need to add the HTML for the widgets. This can't be added using Google Tag Manager as it needs to be placed in the HTML of your page.

Do you have any other questions? Let us know! 😊

Did this answer your question?