By: Ativ Patel || 10/14/2020
To get started, make sure you have set up your property in Google Analytics and have the code copied to your clipboard or have it handy. To get the Google Analytics code into Netlify, we will be using the snippet feature in the Netlify dashboard. The snippet feature in Netlify is a great user experience because it will allow you to add Google Analytics and other javascript code snippets before closing your </head> or </body> tag in ALL of your html files in a few simple steps.
Here are the steps to follow to get Google Analytics (a javascript snippet) into all of your html files on Netlify:
If you want to learn more, check out Netlify docs on Snippet Injection: https://docs.netlify.com/site-deploys/post-processing/snippet-injection/