Back to Documentation
Google Integrations

Google Tag Manager (GTM) Setup

Add your Google Tag Manager container ID to your IHASHOP store. Manage Google Analytics, Google Ads, Meta Pixel, and other measurement tags from one central platform without editing theme files.

What Is Google Tag Manager?

Google Tag Manager is a tag management system that allows you to manage analytics, advertising, and conversion tracking tags in your store from one central platform.

Google Tag Manager is not a visitor measurement or reporting tool by itself. It manages the tags used by measurement services such as Google Analytics and advertising systems such as Google Ads.

With GTM, instead of adding code from different platforms separately to your theme files, you can configure and manage these tags through the Google Tag Manager interface.

Examples of tags that can be managed through Google Tag Manager include:

  • Google Analytics 4
  • Google Ads conversion tags
  • Google Ads remarketing tags
  • Meta Pixel
  • Other supported analytics and advertising tags

This structure makes tag management easier, especially for stores that use multiple measurement or advertising platforms.

Is Google Tag Manager Required?

No. Google Tag Manager is not mandatory.

When you only use Google Analytics 4, it is sufficient to enter the GA4 measurement ID directly into the relevant field in the IHASHOP administration panel.

You can decide whether GTM is necessary based on the following situations.

When You Only Use Google Analytics

Google Tag Manager is not required.

You can add the Google Analytics 4 measurement ID beginning with “G-” directly under:

Settings → SEO and Analytics

When You Use Multiple Measurement and Advertising Tags

When you use Google Analytics, Google Ads, Meta Pixel, and other analytics services together, Google Tag Manager makes it easier to manage all tags from one central platform.

When You Work with an Agency

Using Google Tag Manager may allow an agency to manage measurement and advertising tags without requiring direct access to the store administration panel or theme files.

What Is a GTM Container ID?

During Google Tag Manager setup, a container is created for your store.

The container is the area where the tags, triggers, variables, and related measurement configurations used in your store are managed.

Each container has its own unique ID.

This ID begins with “GTM-” and looks similar to the following:

GTM-XXXXXXX

The information you need to enter into the IHASHOP administration panel is this container ID.

How to Obtain a Google Tag Manager Container ID

Follow these steps to obtain your Google Tag Manager container ID:

  1. Sign in to your Google Tag Manager account.
  2. Create an account for your store or business.
  3. Create a new container for your store.
  4. Select “Web” as the container type.
  5. After creating the container, copy the ID beginning with “GTM-” from the top of the screen.

The copied code will look similar to:

GTM-XXXXXXX

Copy the entire code, including the “GTM-” prefix.

Adding Google Tag Manager to IHASHOP

To add the GTM container ID to your store:

  1. Sign in to the IHASHOP administration panel.
  2. Open Settings → SEO and Analytics.
  3. Find the Google Tag Manager Container ID field.
  4. Paste the container ID beginning with “GTM-” into the field.
  5. Save the settings.

After this process is completed, IHASHOP automatically places the required Google Tag Manager code on the storefront.

Is It Necessary to Add GTM Code to Theme Files?

No.

IHASHOP automatically places both code sections required by Google Tag Manager:

  • The main container code that runs near the top of the page
  • The noscript section used when JavaScript is disabled

You do not need to add these code blocks manually to theme files.

Because the GTM container ID operates through the store’s shared system layer, you do not need to reinstall the integration when you change the store theme.

This approach provides the following benefits:

  • Theme files do not require manual changes.
  • GTM code is not lost during theme updates.
  • Tag management continues after changing the theme.
  • The same code is less likely to be added multiple times accidentally.
  • Technical setup becomes easier to manage.

Difference Between Google Tag Manager and Google Analytics

Google Tag Manager and Google Analytics are not the same tool.

Google Analytics measures and reports visitor activity and e-commerce behaviour in your store.

Google Tag Manager manages how Google Analytics and tags belonging to other platforms operate within the store.

In simple terms:

  • Google Analytics is a measurement and reporting tool.
  • Google Tag Manager is a tag management tool.

Installing Google Tag Manager alone does not automatically create Google Analytics reports.

When Analytics tracking will be managed through GTM, the relevant Google Analytics tag must also be configured in the Google Tag Manager account.

Important Warning: Duplicate Tracking

Do not activate Google Analytics measurement through both Google Tag Manager and the direct GA4 field in the IHASHOP panel at the same time.

For example, when:

  • A GA4 tag has been configured inside Google Tag Manager, and
  • The GA4 measurement ID has also been entered under Settings → SEO and Analytics

the same visit or event may be sent to Google Analytics through two separate methods.

This may cause:

  • Page views to be counted twice
  • User numbers to appear higher than they actually are
  • Add-to-cart events to be recorded twice
  • Purchase events to be reported twice
  • Revenue data to appear incorrectly inflated
  • Conversion rates to be calculated inaccurately

The rule is simple:

Configure Google Analytics either through Google Tag Manager or directly through the IHASHOP panel.

Do not use both methods at the same time.

Which GA4 Setup Method Should Be Used?

Choose one of the following methods according to your requirements.

Direct GA4 Setup Through the IHASHOP Panel

This method is suitable when:

  • You only use Google Analytics
  • You want a simple and fast setup
  • You do not need to manage multiple advertising tags centrally

With this method, the GA4 measurement ID beginning with “G-” is entered directly into the IHASHOP administration panel.

GA4 Setup Through Google Tag Manager

This method may be preferred when:

  • You use multiple analytics and advertising tags
  • You want to manage Google Analytics and Google Ads configurations centrally
  • You also use tags from other platforms, such as Meta Pixel
  • An agency manages your tracking setup

When GA4 is configured through GTM, do not also use the direct Google Analytics measurement ID field in the IHASHOP panel for the same tracking property.

How to Check Whether Google Tag Manager Is Working

You can use GTM’s Preview feature to verify the Google Tag Manager connection.

Follow these steps:

  1. Open your Google Tag Manager account.
  2. Select the relevant container.
  3. Click Preview.
  4. Enter your store URL.
  5. Start the connection.
  6. Visit several pages in your store.
  7. Review the events and triggered tags in the GTM preview screen.

When the connection is configured correctly, Google Tag Manager can display the events generated on storefront pages and the tags triggered by those events in real time.

What Should You Check If GTM Is Not Working?

When the Google Tag Manager connection does not appear, review the following points.

Check the Container ID

Make sure the entered ID begins with “GTM-”.

The code should not contain spaces, quotation marks, or additional characters at the beginning or end.

Confirm That the Settings Were Saved

After adding the GTM container ID, make sure you saved the settings.

Entering the ID and leaving the page without saving prevents the connection from becoming active.

Check That You Selected the Correct Container

When you have multiple Google Tag Manager containers, make sure you are using the ID of the Web container created for your store.

Check the Cache

When your store uses caching or a CDN, an older version of the page may still be displayed.

Wait a few minutes and reload the storefront page.

Disable the Ad Blocker

Some browser extensions may block Google Tag Manager requests.

Repeat the test with the ad blocker disabled or in a private browsing window.

Test on the Storefront

Google Tag Manager operates on the customer-facing storefront.

Perform the test on publicly accessible store pages instead of inside the administration panel.

How Are E-Commerce Events Used with GTM?

IHASHOP sends standard e-commerce events generated in the store to a shared data layer that Google Tag Manager can read.

This data layer is called the dataLayer.

Examples of events generated in the store include:

  • Product view
  • Add to cart
  • Begin checkout
  • Purchase

These events can be read by Google Tag Manager through the dataLayer.

In GTM, the relevant events can be used as triggers and connected to different tags.

For example, the same purchase event can be used to trigger:

  • Google Analytics measurement
  • Google Ads conversion tracking
  • Another supported advertising or analytics tag

This allows a single e-commerce event generated in the store to be used by multiple measurement and advertising platforms.

Important Considerations When Using Google Tag Manager

For a reliable measurement structure, pay attention to the following points:

  • Do not activate the same tag through multiple methods.
  • Do not run GA4 through both GTM and the direct IHASHOP panel field.
  • Use the correct container ID beginning with “GTM-”.
  • Verify the GTM connection through Preview mode.
  • Confirm that tags are triggered by the correct events.
  • Check whether e-commerce events are reaching the dataLayer.
  • Remember that ad blockers may interfere with testing.
  • Perform tests on the storefront instead of the administration panel.

Next Step

After completing Google Tag Manager setup, continue with the “GA4 E-Commerce Events: Automatically Submitted Data” article.

This article explains how IHASHOP sends product views, add-to-cart actions, checkout starts, and purchase events to the dataLayer and how these events can be used by Google Analytics and Google Tag Manager.