Member-only story

Setting Up Google Analytics in an Angular Application

Get user insights from your Angular Application with Google Analytics

Mwiza Kumwenda
4 min readFeb 20, 2020
Photo by Webaroo on Unsplash

In this guide, we will create a simple Angular starter application. Then we will setup or configure Google Analytics for the application. Finally, we will monitor user activity of the application in the Google Analytics dashboard.

Google Analytics is a web analysis service from Google. The service can be used in tracking and reporting real time data related to user activity on your website.

Create an Angular application

To create an Angular application within a workspace named my-app. Run the following CLI command:

$ ng new my-app

Sign in to Google Analytics

Sign in to Google Analytics to create an analytics account and get a Tracking Id to be used in the application.

Google Analytics can be found on the link provided here.

Setup Account

Once Signed in, you will be presented with the Google Analytics home page that looks like the one below.

Click on the Admin button at the bottom left corner of the Google Analytics home page.

--

--

Mwiza Kumwenda
Mwiza Kumwenda

No responses yet