---
updatedAt: 2025-01-29T10:32:42.000Z
agentTools:
  projectIndex: https://triplewhale.readme.io/llms.txt
---

# Sessions

sessions

# Overview

Sessions represent the total number of website sessions, as captured by Triple Pixel. [Learn how Triple Whale defines and tracks sessions.](https://kb.triplewhale.com/en/articles/8048283-web-analytics#h_329062b631)

> 📘 Sessions = Total count of unique website sessions

The calculation is based on data in the [Website Analytics](https://triplewhale.readme.io/docs/web-analytics-table) table.

***

### Detailed Breakdown

The formula above is derived from the following components:

* **Sessions** = `SUM(sessions)` --> [Website Analytics](https://triplewhale.readme.io/docs/web-analytics-table) table
  * `sessions` = `COUNT(session_id)` --> [Sessions](https://triplewhale.readme.io/docs/sessions-table) table

# Insights and Actions

Sessions measure the total number of Triple Pixel website sessions, providing insights into traffic trends and the effectiveness of your marketing efforts.

* **Monitor Traffic Trends**: Use session data to track increases or decreases in website visits, helping you gauge the impact of campaigns or seasonal changes.
* **Evaluate Marketing Campaigns**: Pair session counts with campaign performance metrics to determine which efforts are driving traffic.
* **Identify Audience Behavior**: Analyze session trends alongside user demographics or geolocation to understand your audience better.

### Related Metrics

* **Conversion Rate (CR)**: Combines with sessions to reveal how effectively visits translate into purchases, highlighting website performance.
* **Bounce Rate**: Complements sessions by showing how many visitors leave without engaging, helping identify potential site issues.
* **Average Session Duration**: Offers insights into user engagement, helping assess the quality of the traffic your site receives.

# Example Use

### Prompt

> How many website sessions where there in the past 30 days?

### Response

![](https://files.readme.io/55983acd8a9a87869f65e04b6c124f4f1e2a391a2a5ec46eb6151947b64307b5-image.png)

### Query

```sql
SELECT
  SUM(wa.sessions) AS total_sessions
FROM
  web_analytics_table AS wa
WHERE
  wa.event_date BETWEEN CURRENT_DATE() - 30 AND CURRENT_DATE()  - 1;
```