You can begin to collect data in measurement and advertising products, such as Google Analytics and Google Ads conversion measurement, by adding one or more tags to your website. You can add tags using the Google tag (gtag.js), which requires JavaScript code changes, or a tag management system like Google Tag Manager, which requires configuration changes within the tag management system.

If you want to deploy measurement and advertising tags in a mobile app, you can use the Google Analytics for Firebase SDK. Once you deploy the SDK, you can also use Google Tag Manager to modify and route data.

What is a "tag"?

What is the Google tag?

What is Google Tag Manager?

In Google documentation, Google tag examples consist of gtag.js code, while Tag Manager examples provide steps to configure tags.

Usage example

The following example illustrates the difference between use of the Google tag and Tag Manager.

This Google tag shows a snippet that you could add to each page of your website. The tag ID in the snippet enables measurement for Google Analytics and Google Ads.

<script async

  window.dataLayer = window.dataLayer || [] ;
  function gtag(){dataLayer.push(arguments);}
  gtag( 'js', new Date () ) ;

  gtag( 'config', 'TAG_ID');

To use Tag Manager to enable measurement for Google Analytics and Google Ads, you would create a tag for Google Analytics and a tag for Google Ads Conversions, which you would then configure to fire on the same trigger. After publishing the container, the changes are available instantly on your website. See Google Ads conversions to learn more.

Tags supported by Google tag and Tag Manager

The Google tag (gtag.js) and Tag Manager provide the following tag support:

Tag Type gtag.js Tag Manager
Google Analytics 4 Yes Yes
Google Analytics: Universal Analytics Yes Yes
Google Ads Conversions Yes Yes
Google Ads Remarketing Yes Yes
Floodlight Yes Yes
Google Surveys Website Satisfaction No Yes
Third-party tags No Yes

In addition to the Google measurement products listed here, Tag Manager supports a wide variety of third-party tags. The Community Template Gallery contains additional tag and variable templates maintained by third parties. You can also create and share your own tags with custom templates.