πŸ“ˆ Analytics & Container Scripts

How to use UA & Analytics for your game on Trail?

🚧

Optional Power Tool

This feature is in its early stages and requires Javascript & Analytics/UA experience to use.

We'll work closely with you as a partner to enable whatever UA and analytics need you might have.
Please reach out to us on Discord to discuss and learn more.

Trail supports a myriad of ways to get actionable insights for optimizing your marketing and understanding your players. Supporting your analytics stack (e.g., Facebook Pixel, Google Tag Manager, and other custom integrations) is incredibly important for us at Trail.

Playing games on the web isn't like playing an installed app - it all takes place within a website. Playing your game either on Trail.gg or through an embed on your own page, it always happens through an iFrame called a "container".

πŸ“˜

What is a Trail Container?

A container is an iFrame where the game runs; on Trail.gg or in an embed. JavaScript can be added to the container to run while the game starts. This lets you add scripts to integrate third-party services like Google Tag Manager and Meta Pixel, just like you would to a website.

Container scripts are optional. You can just leave them empty without any issues.

1143

A script for Google Tag Manager is added to the container, and will run in the iFrame when the game launches.

Documentations for UA/Analytics Services

Integrating Google Tag Manager

Integrating Meta Pixel

πŸ“˜

How do I create containers to write scripts in?

Click here to learn how to create and edit containers.