Solved

How to track the start and end of a user session

  • 12 July 2023
  • 1 reply
  • 268 views

How to configure my app such that when a user session starts or ends an event is sent or recorded. Right now, I have initialized my aplitude using amplitude.getInstance().init().

icon

Best answer by Saish Redkar 12 July 2023, 19:09

View original

1 reply

Userlevel 7
Badge +10

Hi @Shivani1999 

If you are using any of the SDKs, then Amplitude can track the Start Session and End Session events using the beginning and ending times of each session by session ID.

You can easily turn on tracking for these events by adding the following lines of code before initializing the SDK:

 

More on this here . Hope this helps.

Reply