GUIDES

How to set up web analytics tracking

2min

This feature allows for integration with many web analytics tools since they work by loading a JS snippet.

If you decide to use Google Analytics, here is what you need to do.

Google Analytics 4 is the next-generation measurement solution, replacing Universal Analytics. On July 1, 2023, standard Universal Analytics properties stopped processing new hits. If you still rely on Universal Analytics, we recommend you use Google Analytics 4 going forward.

1

To add the Google Analytics tracking code to your documentation portal, you’ll need a piece of code known as the β€œGlobal Site Tag.”

You can find this in your Google Analytics admin dashboard. Locate the tracking code under Admin -> Data Streams -> Web stream details.

2

Copy the global site tag below into the Custom JavaScript field under Space Settings -> Custom Code.

Globat site tag code
Globat site tag code
ο»Ώ
3

Make sure you replace the insert measurement ID with your own ID.

JS
ο»Ώ
4

After the code is added, clickΒ SaveΒ and publish to production.

For security reasons, custom code is only included on a custom domain.

ο»Ώ

ο»Ώ

πŸ€”
Have a question?
Our super-smart AI, knowledgeable support team and an awesome community will get you an answer in a flash.
To ask a question or participate in discussions, you'll need to authenticate first.

ο»Ώ