# How to use Google Analytics on documenter-generated pages?

**URL:** <https://discourse.julialang.org/t/how-to-use-google-analytics-on-documenter-generated-pages/76166>\
**Category:** Tooling\
**Created:** [February 10, 2022, 1:57pm UTC](https://discourse.julialang.org/t/how-to-use-google-analytics-on-documenter-generated-pages/76166 "2022-02-10T13:57:28Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Post date:** [February 10, 2022, 1:57pm UTC](https://discourse.julialang.org/t/how-to-use-google-analytics-on-documenter-generated-pages/76166/1 "2022-02-10T13:57:28Z")

</div>

In theory [[Documentation](https://juliadocs.github.io/Documenter.jl/stable/lib/internals/writers/#Documenter.Writers.HTMLWriter.HTML), [2016 merged pull request](https://github.com/JuliaDocs/Documenter.jl/pull/388) ] it is possible to simply pass `analytics = "G-XXXXXXXXXX` to the `makedocs` call, but I receive instead the warning: `Unknown keywords: analytics = G-XXXXXXXXXX` and no Google analytic code is built in the documentation. Where am I wrong ?

---

<div class="post-metadata">

**Author:** ![pfitzseb](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/pfitzseb/32/45566_2.png) [@pfitzseb](https://discourse.julialang.org/u/pfitzseb)\
**Post date:** [February 10, 2022, 2:04pm UTC](https://discourse.julialang.org/t/how-to-use-google-analytics-on-documenter-generated-pages/76166/2 "2022-02-10T14:04:47Z")

</div>

You need to pass that kwarg to `HTML()`, not `makedocs`, as the docs indicate. See e.g. [here](https://github.com/SciML/DiffEqDocs.jl/blob/76c509a992d0f0ad82d4b7bf47a647788b0c5017/docs/make.jl#L17).
