In this guide, we will show you how to delete the container in your GTM account, create a backup file with container settings to return to it later (if needed), remove the GTM snippet from the website, and answer the frequently asked questions about container deletion.
Before deleting the GTM container, it is worth exporting its current version. This will be helpful if you decide to recover it or use the previous configurations as a reference for a new container.
To export the container, choose the container you want to delete (steps 1 and 2 below show how to do this), click "Export Container," → choose a container workspace or version to export.
Click "Export" in the upper right corner. The file in JSON format will be downloaded to your computer. Keep the file in a secure location so you can access it later if necessary.
Navigate to GTM → choose an account (in case you have a few) that has the container you want to delete.
Click on the "Admin" tab, and in the column on the right side, choose the container you want to delete if you have a few containers.
To delete the container, click on "Container Settings" → three dots in the upper right corner → select the 'Delete" option. This action will trigger a "confirmation dialog" to ensure the user is certain about the deletion.
Removing the GTM code snippet depends on how you added it to the website - manually or using plugins for CMS.
The
section:And
section:You should delete both of these snippets and save the changes.
If you have used the plugin to add the GTM snippet code, you can deactivate or remove the plugin.
Clear your website’s cache and open your site in an incognito window. Check the source code (right-click → "View Page Source") and search “gtm.js” to make sure that the GTM snippet is gone.
If you are looking for a tool that allows you to easily manage the tags inside a GTM container (and even delete containers in bulk), have a look at GTM Tools. With its help, you can:
See the detailed guide on how to effectively use GTM Tools.
Managing your Google Tag Manager account requires careful consideration and attention to detail. Deleting or restoring containers is a part of GTM account management. Before deleting a container, it is worth exporting a file with container configuration if you need it in the future. After deleting a container, update the code snippets on your website to avoid conflicts and ensure precise data collection.
Yes, you can remove the GTM code snippet from your website. You should remove both the