Skip to main content
All CollectionsTaking Feedback on WebGetting Started
Install Web Widgets with Google Tag Manager
Install Web Widgets with Google Tag Manager

Learn how to install Web Widgets and Microsurveys in your website and platform with the Google Tag Manager

Sonika Mehta avatar
Written by Sonika Mehta
Updated over 4 months ago

Google Tag Manager (GTM) is a free tool that allows you to easily add and manage Javascript tags to your web application without requiring any code changes in your core website or platform.

GTM Users can easily install the Zonka Feedback JS client on their web applications, websites to launch surveys without any technical knowledge.

Here are the step-by-step instructions for installing Zonka Feedback with Google Tag Manager using custom tags.

In this article

📖 Note

Skip step 1 and 2 if you already have Google Tag Manager installed on your website or platform.


Set Up Google Tag Manager

Here's how you can create a Google Tag Manager Account.

  • Go to Google Tag Manager and sign in with your Google account.

  • Click on Create Account.

  • Enter your account name and container name (usually your website's URL).

  • Select your container type (Web, iOS, Android, AMP).

  • Click on Create.

  • Accept the Terms of Service.


Install Google Tag Manager on Your Website

Once you have set up your Google Tag Manager account, here's how you can install the Google Tag Manager on your Website.

  • After creating your account, you will be provided with a container snippet.

  • Copy the code provided and paste it into your website’s HTML, just below the opening <head> tag, and just below the opening <body> tag.

  • This allows Google Tag Manager to manage your tags.


Create a New Tag for Zonka Feedback

To get started with adding Zonka Feedback Widgets in your Website or Platform, you will need to create a new tag in your Google Tag Manager for Zonka Feedback.

Here are simple steps to create a new tag in your GTM account.

  • Log into Google Tag Manager and click on the container you created.

  • In the left-hand menu, click on Tags.

  • Click on the New button.

  • Click on Tag Configuration.

  • Select Custom HTML Tag.

  • Once a new tag is created, you can now insert the embed code in GTM.

  • In the HTML text box, paste the Zonka Feedback embed code. You can find the embed code from here (choose the right workspace while copying the code).

  • The code should look something like this:

<!-- Zonka Feedback JavaScript Code Starts-->

<script id="zfEmbed">

window._zfQueue = window._zfQueue || []; function _zf(){_zfQueue.push(arguments); }

(function() { ZonkaFeedback = function (en, fb ){document.body.addEventListener(en, fb ,

false); }; var sc, w, d = document, ce = d.createElement, gi = d.getElementById, gt =

d.getElementsByTagName, id = "zfEmbedScript"; if (!gi.call(d, id)) { sc = ce.call(d, "script");

sc.async=!0;sc.id = id; sc.src = "https://us-js.zonka.co/

CUSTOMCODE"; w = gt.call(d, "script")[0];

w.parentNode.insertBefore(sc, w); }})();

</script>

<!-- Zonka Feedback JavaScript Code Ends-->

Next, choose a trigger to initialize the code installed.

  • Click on Triggering.

  • To load the Zonka Feedback widget on all pages of your website, select the All Pages trigger. Otherwise, you can set up a custom trigger to specify particular pages where you want the widget to appear.

  • To set up a custom trigger, click on the + button, name your trigger, select Page View as the trigger type, and configure the conditions based on your requirements.

  • Click on the Save button to save your new tag

  • Once saved, click on the Submit button in the top right corner of the Google Tag Manager dashboard.

  • Add a version name and description (e.g., "Added Zonka Feedback widget") and click Publish.

  • This will make your changes live on your website.


By following these steps and referring to the visual guide, you will have successfully integrated the Zonka Feedback widget into your website using Google Tag Manager. This allows you to easily collect feedback and survey responses. The widget will be active on the specified pages, and you can customize the triggering conditions based on your needs.

Did this answer your question?