Google tag manager - thank you page script error

We have an GTM error on thank you page that:

“ tag must not be included in a

For active GTM checkout pages, we added GTM codes to preferences page-Additional Google Analytics JavaScript

and checkout - order status page

With these additions, GTM is active and working but on thank you page, we have an error of

“ tag must not be included in a

However, as you know we cannot edit checkout scripts. So how to fix this error? What am I missing here

2 Likes

@enesu can you let me know how you’ve fixed this issue? We experience thesame.

1 Like

hi @enesu @Lau3 i have added gtm it was working fine no error.

1 Like

Added how ?

When i add my GTM script in Settings=>Checkout=> Order Status Page ( Additional scripts ), i get the following error:

tag must not be included in a
1 Like

Seems a lot of people struggling with this. I found also in Shopify store that when I place not only GTM snippet but something else to Additional Scripts section in Checkout settings , it goes to

..
if you inspect code of Order status page then.

That’s why we see this error in Tag Assistant.

So, I can not understand what the problem and why Shopify can noy help us to deal with it.

1 Like

Tried to paste another tags to Order Status page and they also were placed inside this magic div. I also added Pinterest tag but I couldn’t see it anywhere in the source code.

Shopify support tells me that :

23:24 Grayson (Support Advisor): Ah ok, I see. Taking a look, Google Tag Manager needs to go into the checkout files, which you don’t have access to for security reasons. It’s only available for our Plus subscription.

23:26 Dmitry Podoleev: Not always so, if you place it to Order status page also you can see how many page views you have. It doesn’t really need checkout files

23:28 Grayson (Support Advisor): In the case of GTM specifically, however, it does according to our Google Tag Manager help document. The Order Status page can have a lot of great tracking pixels added, but the GTM is saying it needs the checkout.liquid code to work.

23:31 Grayson (Support Advisor): OK, what specifically is the Snap pixel trying to do? Because it may be that it isn’t compatible. I’d love to take a look at this closer.

But it’s surprise to me for example if I don’t need this Checkout stage why am I not allowed to place my tags to Order status page.

I’m facing the same problem.
Has anybody found a solution to this?

@enesu you need to add your gtm script into the settings → checkout page → addition script that was working on thank you page.

@fsaeidinik @Mitrodol @alamkamran @Lau3

facing same issue, can anyone help ?

I think your code has bug.

facing same issue. did you ever resolve the problem?

Just got the same issue, did anyone found a solution to this?