Set up Google tags and Tag Manager

Use this guide to connect Google Analytics, Google Ads, or Floodlight to your site, or to install a Google Tag Manager container. It is intended for site administrators and editors who have access to the theme's integration settings.

Before you begin

  • Obtain the tag or container ID from the Google account that should receive the site's data.
  • Check whether another plugin, a custom script, or an existing Tag Manager container already installs the same tag.
  • Decide which page views, events, and conversions you need to verify after saving.
  • Configure the site's consent choices under Settings → POM Theme → Integrations → Cookies when using the theme's cookie notice.

A Google tag connects the site to Google measurement and advertising products. A Tag Manager container holds tags and their firing rules, which are managed in Google Tag Manager. Their IDs belong in different fields.

Choose the correct field

Open Settings → POM Theme → Integrations → Statistics. The Google tags and Tag Manager section contains these controls:

Field Value When to use it
Google tag One G-, GT-, AW-, or DC- ID The primary tag installed directly by the theme. An Ads-only site can put its AW- ID here.
Additional Google tags One additional Google tag ID per row Other tags installed directly by the theme. A primary Google tag is required.
Google Tag Manager container ID One GTM- ID A container whose tags and firing rules you manage in Google Tag Manager.
Second Google Tag Manager container ID A different GTM- ID An optional second container.

Enter only an ID. Do not paste a URL, a script, a gtag('config', ...) command, or several comma-separated IDs. G-, GT-, and GTM- suffixes use uppercase letters and numbers; AW- and DC- suffixes use numbers. Universal Analytics UA- IDs are not accepted.

Install a Google tag directly

  1. Enter the first ID in Google tag.
  2. If you need another Google tag, select Add new under Additional Google tags and enter its ID in Google tag ID. Repeat for each additional tag.
  3. Leave both container fields empty unless the site also uses a real Tag Manager container.
  4. Select Save.
  5. Clear any page cache that still serves the previous HTML.
  6. Follow the verification steps below.

The theme loads gtag.js for the primary ID and adds a configuration command for that ID and each non-empty additional row. Blank additional rows are ignored. It does not create conversion actions or event definitions in your Google account.

Do not repeat the primary ID in the additional rows. Also check for tags installed outside these fields: the theme does not inspect the contents of your Tag Manager containers or other plugins.

Install a Tag Manager container

  1. Enter the container's GTM- ID in Google Tag Manager container ID.
  2. Use Second Google Tag Manager container ID only if you intentionally need a different second container.
  3. If every Google tag is managed inside the container, leave Google tag and Additional Google tags empty.
  4. Configure and publish the required tags and firing rules in Google Tag Manager.
  5. Select Save in WordPress and clear any page cache.
  6. Verify the container and its tags with Tag Assistant.

The theme adds the container script and its no-JavaScript iframe. A direct Google tag and a Tag Manager container can coexist, but you must ensure that they do not install the same measurement twice.

Change an existing configuration

If an ID is in the wrong field, move it to the appropriate field and clear its old location before saving:

  • Put a direct Google tag in Google tag, or in an additional row if there is already a primary tag.
  • If exactly the same ID is already in the correct field, remove the extra entry instead of adding another copy.
  • Keep each intended GTM- container in its container field.
  • For an existing UA- entry, obtain the current Google tag ID from the account owner; changing the prefix does not convert the old ID.

The theme does not move or reinterpret existing IDs automatically. A format error stops the whole Statistics submission before it is saved. Use Back, correct the listed fields, and save again. The previously saved configuration remains in use until a valid submission succeeds.

Verify the result

  1. Open a public page and connect it to Google Tag Assistant.
  2. Confirm that the expected Google tag and container IDs appear.
  3. Check that direct tags use gtag.js, while gtm.js and ns.html identify only your intended GTM- containers.
  4. Test the site's consent choices, including a new visit and a returning visit with a saved choice. Confirm the expected tag behavior for Analytics and Ads.
  5. Trigger representative page views, events, and conversions. Confirm receipt in the appropriate Google product and check for duplicates.

When the theme's cookie notice is enabled, its consent defaults and any saved consent choices are queued before the theme's Google scripts. Verify any separately installed consent tools against their own configuration.

Troubleshooting

The settings page rejects an ID. Check its prefix, uppercase letters, and destination field. Paste only the ID from the Google account. Empty optional fields are allowed.

Additional tags cannot be saved on their own. Put the first ID in Google tag. The additional rows extend that primary installation.

The old snippet still appears. Check the saved fields, page caches, other plugins, and custom scripts. A theme setting does not remove a separately installed snippet.

The tag loads but conversions are missing. Check the event implementation, conversion action, firing rules, consent choices, and destination account. Loading an ID is only the installation step.