Google analytics is a free service offered by Google that provides statistics about the visitors and traffic to our website. It provides a more valuable input about the visitors and geographies. It also provides input about the behavior of the visitor when they use our website. The following are the steps for registering Google analytics to your application.
Creating a Google analytics account: We can create a Google analytics account with an existing Gmail account or a new Gmail account by performing the following steps:
- Open the browser and paste in the analytics URL (https://analytics.google.com/analytics)
- Click on the
SIGNUP
button - Fill out your live application URL and form information
- Click on the
Get Tracking ID
button
Integrating tracking code into our application: After a successful signup, we can integrate the generated global site tag into our application. Take a look at the following sample global site code in index.html
:
<head> ... <script async src=...