Search code examples
google-tag-managergoogle-optimize

Google Optimize is firing continuously on all site pages


We have one test where the 'activation event' is set to 'continuously'; this test is confined to the homepage with a 'URL matches'. However, when we look at other pages on the site, we can see that Optimize is firing continuously on all site pages. Why is this happening? And how do we restrict the continuous firing to the one URL in the one test? We are adding the Google Optimize tag to our site via GTM.


Solution

  • Continuously means you're activating Optimize whenever Optimize detects a DOM-change, instead of on a page load. When Optimize is activated, that is when it evaluates if page targeting and audience is matching any active experiments, and applies the experiment changes if that is the case. Whether you activate Optimize on Page load or by Continuous activation, Optimize needs to activate first in order to evaluate if a test should be triggered or not.

    If you don't want Optimize to observe for changes on the whole page, you would either need to remove it on all other pages, or you can implement a specific Activation Event that fires once in the places where you want Optimize to reevaluate, e.g. on virtual page loads.