Back to blog

Google Tag Manager Guide: Set Up the Google Tag and GA4

Shusaku Yosa

GTM(Googleタグマネージャー)とは?導入方法と使い方を解説

Google Tag Manager (GTM) manages and deploys website tags. GA4 analyzes the events it receives; the Google tag connects a website to Google measurement destinations. Start with a tag inventory, install or reuse one GTM container, configure the Google tag, validate actual receipt, and publish a documented version.

Understand the three components

Component

Identifier

Purpose

GTM web container

GTM-…

Manages tags, triggers, variables, and versions

Google tag

GT-…, G-…, and other supported IDs

Connects measurement to configured destinations

GA4 web data stream

G-… measurement ID

Receives website events in a GA4 property

A G- measurement ID can be used when configuring the Google tag. Check the destination property, not just the ID prefix. GTM reduces repeated code edits for supported tags, but initial installation, custom dataLayer messages, single-page applications, and form success signals may still need developer support.

Inventory existing tags before installing anything

List direct Google tag installations, CMS integrations, plugins, existing GTM containers, and advertising tags. Record each destination, owner, consent dependency, and event. Installing GTM alongside an existing implementation can send duplicate page views or events. Plan a controlled replacement rather than deleting a tag without checking its dependencies.

Choose events from your measurement KPIs. A button click, a form interaction, and an accepted inquiry are different outcomes. Only a confirmed success signal should represent a completed inquiry. This distinction also matters when assessing paid search performance.

Set up and validate the Google tag

  1. Create or reuse a Web container. Install the supplied container snippets in the head and body positions specified by GTM, checking all relevant page templates.
  2. Create a Google tag and enter the intended tag ID. The current basic Google workflow uses the Initialization - All Pages trigger.
  3. Check whether the Google tag already sends page_view before adding another page-view event tag.
  4. Open Preview and connect Tag Assistant. Test the intended pages, actions, and consent states.
  5. Confirm receipt in GA4, using DebugView where appropriate. Inspect the event name, parameters, destination, and expected count.
  6. Publish a version with a clear name and change note. Repeat the essential checks on production and retain a tested rollback version.

Follow Google's current setup instructions. “Tag fired” in Preview is only one checkpoint: it does not prove that the correct property received a valid event. Advertising tags also need correct success conditions, values, and currency. A separate Conversion Linker should not be added automatically to every configuration; check whether a Google tag already loads on all pages and follow the applicable requirements.

A release test sheet

This fictional example uses cta_click for a website call-to-action. Adapt names and conditions to the actual application.

Test

Expected result

If it fails

Click the CTA once

One cta_click with the correct button_name

Inspect trigger scope and duplicate handlers

Click elsewhere

No cta_click

Narrow the trigger

Submit an invalid form

No successful-inquiry event

Separate interaction from acceptance

Reload the success page

No unintended repeated success

Review success identifiers and deduplication

Change consent state

Behavior matches the consent design

Check defaults and update timing

An outbound click is not cross-domain measurement

A click to a booking provider shows that someone left for that service. It does not establish a completed booking. Cross-domain measurement requires the same tag ID from the same web stream on the participating sites, GA4 domain configuration, and verification that the _gl parameter survives links, forms, and redirects. See Google's cross-domain requirements.

If you cannot control tagging on the external service, browser cross-domain configuration alone cannot guarantee measurement of its completed bookings. Investigate a supported completion integration or provider reports, and keep outbound clicks separate from completed outcomes.

Separate editing from publishing

Level

Permissions

Operational meaning

Account

User / Admin

Account access and administrator responsibilities

Container

Read / Edit / Approve / Publish

Viewing, workspace editing, version creation, and release authority

Use Google's permissions model, appoint a reviewer and publisher, and document the previous working version. If you use GTM for ownership verification, check the separate Search Console verification requirements.

When server-side tagging becomes relevant

Server-side tagging provides another place to process and control measurement data. It can run on infrastructure beyond Google Cloud, but requires hosting, monitoring, maintenance, and a deliberate data design. It does not remove consent obligations or automatically bypass browser restrictions. Review Google's server-side overview after stabilizing the basic web implementation.

Back to blog