The process involves the following high level steps:
- If you are already hosting static files somewhere on your own domain, it should just be a matter of downloading and adding the JS file. Otherwise you can follow one of these guides for hosting a static file on AWS or GCP, or use another method of your choice:
- Once you have a JS tracker available, you can add the JS tag to your site. There are three options described below for adding the tracker to your website.
If manually inserting the tag into your website: Snowplow Insights users can generate a JS tag in the Insights Console here. Other users can use and edit the standard tag from here.
N.B. Be sure to use the correct collector for production or development.
- Once you’ve generated your tag add it to all the pages you’d like to track. There are a number of options depending on your technology stack:
- Use a Tag Manager such as Google Tag Manager. Users of Google Tag Manager can use the Snowplow Analytics Custom Template.
- Place the tag directly into your codebase. Typically this will be placed into the <head> element of your page or in a similar, suitable, location if using a Single Page Application framework.
- Use the Snowplow Plugin in the Analytics NPM package.