Skip to content
Home » Blog » How do I setup a server container in GTM for BigCommerce?

How do I setup a server container in GTM for BigCommerce?

To set up a server container in GTM for BigCommerce, follow these steps:

  1. Log in to your Google Tag Manager account.
  2. Click on the “Admin” tab in the top menu.
  3. Click on the “Server Container” option under the “Container” section.
  4. Click the “Create Container” button.
  5. Give your container a name, select the appropriate country and click the “Create” button.
  6. After your server container is created, copy the provided container snippet.
  7. In your BigCommerce store, go to the “Advanced Settings” menu and click on “API Accounts.”
  8. Click on the “Create API Account” button and give your API account a name.
  9. Select the “Web services” option and click on the “Save” button.
  10. Click on the “Create Token” button and copy the provided token.
  11. Return to GTM and go to the “Tags” menu.
  12. Click on the “New” button and select the “Custom HTML” tag type.
  13. Paste the server container snippet into the tag configuration and replace “GTM-XXXXXXX” with your GTM container ID.
  14. Add the following code to the end of the container snippet, replacing “YOUR-API-ACCOUNT-NAME” and “YOUR-API-ACCOUNT-TOKEN” with the corresponding values:
<script async src="https://www.googletagmanager.com/gtm-server?id=GTM-XXXXXXX&api=YOUR-API-ACCOUNT-NAME&auth=YOUR-API-ACCOUNT-TOKEN"></script>
  1. Click on the “Save” button to create the tag.
  2. Go to the “Triggers” menu and create a new trigger.
  3. Select the appropriate trigger type for your server container implementation.
  4. Click on the “Save” button to create the trigger.
  5. Go to the “Variables” menu and create a new variable.
  6. Select the appropriate variable type for your server container implementation.
  7. Click on the “Save” button to create the variable.
  8. Go back to the “Tags” menu and edit the tag you created earlier.
  9. Add the trigger you created earlier to the tag configuration.
  10. Add any relevant variables to the tag configuration.
  11. Click on the “Save” button to finalize the tag setup.

Once you have completed these steps, your server container should be set up and ready to use with your BigCommerce store.