It isn't possible to know who is actively logged on at any given time as that isn't how stateless protocols work. But you can check the Azure AD Sign-in logs or Unified Audit Log in the M365 Admin center to see who has logged on within the past N period of time.
How to get all the users info in a SharePoint who is currently logged on
Raj Shekar
21
Reputation points
Hi All,
How to get all the users info in a SharePoint who is currently logged on
2 answers
Sort by: Most helpful
-
-
Baker Kong-MSFT 3,801 Reputation points
2020-08-04T02:32:10.51+00:00 Hi @Raj Shekar ,
As I understand, SharePoint does not provide any means to figure out who is currently logged on as HTTP is a stateless protocol, you don't know if a user is currently online, even if he/she just requested a site from your SiteCollection a few seconds ago.
Best Regards,
Baker Kong