The global site tag (gtag.js) is now the Google tag. Learn more

Before you begin

Stay organized with collections Save and categorize content based on your preferences.

Before you install tags, you should look at your existing website or app configuration and analyze what measurement products and practices might already be in place. Some questions to consider include:

Measurement goals

Before you begin any measurement product setup, consider what your business goals are first. Some example goals for your business might include:

  • How often an ad is clicked
  • How many new subscriptions come from ad campaigns
  • How many site visits result in cart checkouts
  • What your most successful marketing channels are
  • What the optimal placement of user interface elements is for the highest conversion probability
  • Which products fare best in the ecommerce funnel of the website
  • What actions typically precede a successful conversion

Also consider negative goals by identifying the opposite of the above goals. For example, identifying marketing channels that struggle to produce conversions is a relevant negative goal to help you improve your overall marketing efforts.

Use your business goals to help you decide what products to use, which events you want to measure, what instrumentation you might need, and what reports you'd like to see. These decisions should drive your measurement implementation strategy.

Remember that business goals are not set in stone; they're questions you need to re-evaluate frequently. As you collect more data, additional business questions might emerge that you’ll want to refine in your implementation strategy, too.

Google Tag Manager, Google tag, or Firebase?

If you're new to tagging, you might be asking: What should I use - the Google tag, Google Tag Manager, or Firebase?

If your site platform or Content Management System permits it, Google Tag Manager should be your first choice for deploying analytics and marketing tags. Tag Manager gives you the most flexibility in how and when to deploy site tags. Even if you only need it for a single Google product (such as Google Ads), Tag Manager prepares your measurement plan for possible future product integrations as well.

Google tag: If you haven't tagged your web pages yet, or only intend to tag your pages for one product (e.g. Google Ads) with few changes over time, then a Google tag installation may be the fastest and easiest method to get started. The Google tag is a snippet of code that you add to a web page. Learn more about Google tag installation.

Google Tag Manager: Tag Manager is a robust, fully featured, enterprise- grade tag management system that supports Google, third-party, and custom tags for web and mobile apps. You can add and modify tags through the Tag Manager interface without adjusting the code on your site. In addition, Tag Manager features support for third-party tags, organization features, version control, and enterprise collaboration and security features. Tag Manager features the ability to create custom tag and variable templates that you can share with your team, and you can deploy and use templates in the Community Template Gallery. You can use server-side tagging to move code out of the client side and into the cloud for additional performance and security benefits. Learn more about Tag Manager.

Firebase Firebase is a toolset by Google that supports mobile devices, including iOS and Android. Firebase includes measurement frameworks for Google products such as Google Ads and Google Analytics. Use Firebase if you need to set up measurement on mobile apps.

Your measurement goals may help to inform which tagging tool you should use:

  • If your primary measurement goal is related to Ads performance, consider using the Google tag.
  • If your primary goal is to measure all traffic to your site, consider using the Google tag.
  • If you want to measure Google Ads, Google Analytics, and other measurement platforms, consider using Google Tag Manager.
  • If you want to measure campaigns and usage on mobile devices, use Firebase.

Regardless of your measurement goals, consider installing Google Tag Manager, as it gives you the most flexibility in working with a range of Google (and third-party) measurement and advertising products.

Integration with content management and ecommerce systems

Many content management and ecommerce systems feature turnkey integration with Google measurement products. Before you proceed with adding the Google tag snippet or installing Google Tag Manager in your platform's templates, see if your platform already provides a built-in integration for Google tags by checking the provider's support documentation.

Note that often these integrations might be missing key features and latest updates to the measurement stacks they represent. Be sure to check the documentation and consult platform support, if necessary.

Third-party tag management systems

Google tags are commonly deployed from third-party tag management systems. When using a third-party tag management platform, in all cases you will want to refer to the Google tag version of Google's tag documentation, and whenever possible you should refer to the third-party vendor's documentation.

Existing tag installations and instrumentation

Consider what tag setups you may already have installed. If you have tags already installed and deployed, you should review your tag configuration to ensure it is properly configured and optimized. If you are on an older tag library such as analytics.js or conversions.js, you should upgrade your tag setup to the latest supported method. You should avoid installing redundant tags or tag management systems, and you should try to keep your tag configurations as efficient as possible.

The quickest way to figure out existing tag configurations for web sites is to use Google Tag Assistant. Run Tag Assistant to automatically discover tag configurations and product IDs.

You can also manually search for existing tags in source code.

If there is an existing tag platform, you will also want to investigate any existing instrumentation.

  • Is there an existing dataLayer object? If so, what data appears in it?
  • Does event data appear in your reports? If so, what?
  • How is event data being collected?

Learn more about analyzing existing tag configurations.

For Google Tag Manager installations

Tag Manager installations have additional considerations:

Manage personnel changes

When you first set up a Tag Manager account, put a strategy in place for who will manage the account over the long term, and to define how account ownership will be handled should a member of your team change roles.

Have a strategy that will help to ensure that if someone leaves your organization and their account credentials are terminated, the organization will maintain access to your Tag Manager account. Some organizations delegate administrator roles to multiple users. Others create a dedicated master Google account just for Tag Manager administration for their organization. Choose the system that works best for you.

One Tag Manager account per organization

Set up one Tag Manager account per organization. The organization for which the tags will be managed should create the Tag Manager account. For example, if an agency manages tags on behalf of your company, then your company should create the Tag Manager account and add the agency's Google account as a user.

Empower IT with additional security controls

Your company’s IT department may be wary about the freedom of deployment that Google Tag Manager provides. IT can deploy additional security measures such as Content Security Policies, custom restrictions, and custom template policies.

Use zones to manage access

Agencies can manage their clients' existing accounts in the admin section of Tag Manager. Multiple users can manage the same Google Tag Manager account, and each user can be given different access permissions by the account administrators. Google Tag Manager 360 customers can add and control additional containers using zones.