- Go to Admin > Admin Console > Report Suites, and select the report suite you would like to implement the Average Time Spent on Site metric.
- Go to Edit Settings > Traffic > Traffic Variables, and click Add New.
- Name your new prop Average Time Spent on Site, set it to Enabled, set Path Reports to enabled, and click Save.
- Open your s_code.js file, place the following line of code (replacing XX with the correct traffic variable):
- Save this file, and upload it to your hosting servers.
- Once completed, give the variable some time to gather data, then go to this custom traffic report within the Custom Traffic folder.
- Click Add metrics, and select Average Time Spent on Page.
- The resulting report consists of a single line item, Entire Site, providing you with the Average Time Spent on Site metric (in minutes).
You can then manipulate this report as you would like, such as bookmarking it, adding it as a dashboard reportlet, or trending it. Though the metric is still technically named Time Spent on Page, this method allows marketing reports & analytics to treat your entire site as a single page.