What is the better implementation of Google Analytics for page speed?

We use both Google Analytics and Google Tag Manager, would it be quicker to

  1. Hard code both
  2. Run GA through GTM

1 Answer 1


If you have GTM, you should use it instead of also hard-coding you GA tag. That's what your GTM is for - placing all your tags into one container and managing them all in one place. There's really no sense to have a GTM container loading on your pages and also to maintain a GA tag in the code.

Not only does GTM consolidate all your tags into one container, which is the only tag script that needs to load on your pages, but the tags within load asynchronously in most cases. That translates to faster load times.

That said, GA is a pretty lightweight tag, and UA tags load asynchronously by default. If you're heavily modifying your tag to include various integrations and additional logic, it may load more slowly. Still, with your GTM implemented, there's really no reason to do that. You won't win any milliseconds for sure, and may lose some.

  • I don't see how GTM could possibly be faster. If anything it will be slower because two scripts have to fire instead of one before GA loads. Since it is all asynchronous, the user experience is going to be the same either way, but the data should get to GA faster without GTM. Commented Jul 11, 2017 at 18:04
  • @StephenOstermiller That depends. If he only has a GA tag and no other tags, then there's no point to even implement GTM. But if he has other tags plus GA, then might as well load the GA (and any others) in the background. The difference is, essentially, GTM -> GA vs GTM + GA. The first one is more efficient. Also, we're talking one tag vs two, which means less code on the page. Ultimately, he won't lose much, but won't gain any, and may end up with a maintenance redundancy. Commented Jul 11, 2017 at 18:15
  • Just to clarify, we do use GTM to run multiple tags which we would have to hardcode if we didn't have GTM.
    – GrapeSoda
    Commented Jul 14, 2017 at 10:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.