> ## Documentation Index
> Fetch the complete documentation index at: https://docs.getjurni.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Connect Google Tag Manager

> Find the GTM container ID, connect it in Jurni, and configure tags and event mappings separately.

Use **Google Tag Manager (GTM)** when your tracking team manages analytics and advertising tags in one container. **Connecting the container loads GTM; it does not automatically configure its tags, triggers, or every Jurni event.**

## Find your container ID

Open Google Tag Manager, select the correct account and **web container**, and open **Workspace**. Copy the container ID near the top of the window, beginning **GTM-**. Do not copy a GA4 Measurement ID beginning G- or the numerical account ID.

See [Google's container-ID instructions](https://support.google.com/tagmanager/answer/14847097?hl=en).

## Connect it in Jurni

<Steps>
  <Step title="Check the existing installation">
    Confirm whether the same container already loads through Custom Scripts or the Shopify theme. Decide which installation should own each publishing environment.
  </Step>

  <Step title="Save the container ID">
    Open **Settings → Integrations → Data Integrations → Tracking Pixels**. Enter **Google Tag Manager ID** and select **Save Changes**.
  </Step>

  <Step title="Test with your tracking team">
    In GTM, select **Preview** and connect Tag Assistant to the published Jurni page. Confirm the intended container loads once and the expected tags fire for a real action.
  </Step>

  <Step title="Publish the GTM changes">
    Tags and triggers changed in GTM must also be published there when approved. Saving the container ID in Jurni does not publish a GTM workspace.
  </Step>
</Steps>

## Configure the events you need

Your tracking team should choose the relevant Jurni browser events, map them into GTM where needed, and configure the destination tags. That event mapping is a separate implementation, not a switch created by entering a container ID.

For example, a click on Add to cart and a **successful** add-to-cart are different moments. Use the successful action when the conversion tag is intended to record an item actually reaching the cart.

Share the [event reference](/reference/events) and [Custom Scripts guide](/integrations/custom-scripts) with the implementation owner. Avoid installing a second native GA4 or Meta pixel for the same purpose already handled by GTM.

## Shopify Pages and page targeting

On **Shopify Pages**, the theme may already load GTM. Test the actual `/pages/` URL instead of assuming the Jurni-hosted setup applies identically.

The native GTM field is a shop integration field, not a per-page targeting interface. **Custom Scripts** has separate page-targeting controls when your implementation uses that installation path. Do not configure the same loader through both systems.

## Troubleshooting

**The container appears but an event is absent:** inspect the tag's trigger and the event mapping; installation alone is not event forwarding.

**Tags fire twice:** inspect the native integration, GTM itself, Custom Scripts, and Shopify theme/apps for overlapping installations.

**Preview works but live does not:** confirm the GTM changes were published and test with the intended consent settings. Do not remove consent requirements to force tracking.

## Related guides

* [Google Analytics 4](/integrations/google-analytics)
* [Meta Pixel](/integrations/meta-pixel)
* [Consent and tracking](/integrations/consent-tracking)
* [Integration troubleshooting](/integrations/troubleshooting)


## Related topics

- [Connect Google Analytics 4](/integrations/google-analytics.md)
- [Google Analytics & Meta Pixel Setup](/integrations/ga-meta-pixel.md)
- [Find your integration connection details](/integrations/api-keys.md)
- [Connect the tools your brand uses](/integrations/overview.md)
- [Jurni Event Dictionary](/reference/events.md)
