How to Publish Changes and Version Control in Google Tag Manager

How to Publish Changes and Version Control in Google Tag Manager

Publishing changes and maintaining version control in Google Tag Manager (GTM) is crucial for managing your tags effectively. Here’s a step-by-step guide on how to do it:

1. Make Changes in GTM

  • Before publishing, ensure you’ve made all necessary changes to your tags, triggers, and variables in the GTM workspace.

2. Test Changes in Preview Mode

  • Enable Preview Mode: Click the “Preview” button in the top right corner of GTM.
  • Test on Your Site: Verify that your changes work as expected using the debug console that appears at the bottom of your site.

3. Create a New Version

  • Go to the Workspace: Once your changes are verified, return to the GTM workspace.
  • Click on “Submit”: In the top right corner, click the “Submit” button.

4. Configure the Version

  1. Name and Description:
    • Version Name: Give your version a descriptive name that reflects the changes made.
    • Version Description: Provide a detailed description of what changes are included in this version. This helps in understanding the context of the version later.
  2. Options (Optional):
    • Choose workspace changes: If you have multiple workspaces, you can select which changes to include in this version.
    • Publish and Create Version: Select this option to publish the changes immediately and create a version simultaneously.

5. Publish the Changes

  • Publish Now: If you chose to publish immediately, your changes will be live once you click “Publish.”
  • Schedule Publishing (Optional): You can also choose to schedule the publishing for a later time by selecting the “Schedule” option.

6. Confirm and View the Version

  • Version Confirmation: Once published, you’ll see a confirmation message with details about the new version.
  • View Versions: To see all versions, go to the “Versions” tab on the left-hand menu. Here, you can view a list of all versions created, along with their descriptions and timestamps.

7. Rollback if Necessary

  • Select a Version: In the “Versions” tab, find the version you want to revert to.
  • Click “Actions” -> “Publish”: Select “Actions” next to the version you want to roll back to and click “Publish.” This will revert your container to the state it was in at that version.

8. Manage Version History

  • View Version Details: Click on any version to view detailed information about the changes made in that version.
  • Compare Versions: Use the “Compare” feature to see differences between versions. This is helpful for identifying what specific changes were made.

By following these steps, you can effectively manage and control versions in Google Tag Manager, ensuring a smooth and organized tagging process.