AdWords is now Google Ads. Our new name reflects the full range of advertising options we offer across Search, Display, YouTube, and more. Learn more

Optimize
5K members online now
5K members online now
Everything you need to know about setting up Optimize including creating your account and container, linking to Google Analytics and how to tag your site.
Guide Me
star_border
Reply

Page load delay after removing Optimize script

Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

After my first experiment had ended, I decided to remove the Optimize script from firing through Tagmanager. So I just deleted the single textline without any other changes and published the container.

 

But now I see a 3-4 seconds delay everytime I load a page on my website. I tried to put the Optimize script back on again, and then the delay is gone.

 

What is going on?

1 Expert replyverified_user

Page load delay after removing Optimize script

Visitor ✭ ✭ ✭
# 2
Visitor ✭ ✭ ✭

Fixed. Stupid error. Forgot to remove the page-hiding snippet code.

Page load delay after removing Optimize script

Google Employee
# 3
Google Employee

In case you may ever want to set this up again: the correct way to setup the page hiding snippet for use with GTM, is to pass in the GTM container ID in the inline page hiding snippet.

 

In that case the page will be unhidden as soon as the GTM container loads (if you are not firing Optimize).

 

Its is then recommended to use the GTM Optimize tag (and not just paste the inline Optimize snippet in a Custom HTML tag), since this will ensure that the page will remain hidden, until Optimize also loads.

 

For more on page hiding see:

https://developers.google.com/optimize/

 

https://support.google.com/360suite/optimize/answer/6262084?hl=en