The auto-tracking lighting component allows you to track time automatically from the view page of an object.


The auto-tracking lightning component can be added to any object in Salesforce. I have selected Project as an example in this article


Adding the auto-tracking component to Projects

  • Go to the Projects Tab and click on any Project (name) from the Projects list.
  • From Project view, click the Settings button and click the Edit Page,
  • The screen is redirected to the edit page of the Project. Search for Tab in the search box
  • Drag and drop the "Tab" sidebar towards the right-hand side (the place marked in Red in the screenshot) 
  • Remove the Related tab on the screen that is on the right-hand side below the Save button on the Tabs list
  • Click on the Details tab and select Custom in the list and name it as Track Time on view or any name you wish
  • Click the Done button
  • Scroll to the bottom of the screen or search for "Auto Record" from the list on the left-hand side
  • Drag and drop it into the Auto Tracker column
  • Save the changes by clicking the Save button
  • Now the Auto Tracking component is added to the Project view screen


To activate the Auto Tracking component,

  • Click the Activation button that is before the Save button,
  • Click the "App Record type and Profile" tab in the pop-up, and then click the "Assign to Apps, Record types, and Profiles",
  • Select PK4 TimeTracker, then select Desktop and Phone, in the next screen
  • Select Master and select the profiles from the list to give access to the auto-tracking component to the users and click the next button,
  • You see the list of profiles that you have selected, cross-check the profiles list, and click the Save button,
  • Now the Auto Tracking component is added to the selected profiles,
  • The time is tracked automatically when you are on the view page of a Project. And the hours worked are saved in the TT Details tab.

Note: Salesforce does not allow you to track time for Activities and Tasks. So you cannot add the Lighting component to Salesforce Activities and Tasks.