I had a business requirement to track user activities inside a SharePoint site and guess what? SharePoint have OTB functionality to track who is doing what in the whole site collection. For example: User A is editing documents, User B is downloading some documents and User C is just viewing the content without touching them. This functionality is called Audit Log Reporting.
Configure Audit Log Settings:
- Go to Site Settings and under Site Collection Administration section, select Site collection audit settings.
- Select the events that you want to capture.
- Go to Site Collection Administration section and select Audit log reports.
- Select the report that you want to view. Make sure you have selected the corresponding event in the above steps.
- You will be asked to select a document library where the report will be generated as an Excel document.