# GET /websites/:website_id/traffic

**Resource:** [Websites](./websites.md)  
**MCP tool:** `get_website_traffic`  
**Scopes:** `websites:read`  
**Write operation:** no

Get a website's traffic: page views and visits for a date range, grouped by page path (default), referrer, country, device, browser, or date. Answers "is traffic up or down since we changed X" and "which pages do people actually read". Bot traffic is excluded. Requires traffic reporting to be on (enable_website_traffic_reporting). For finding broken URLs specifically, use get_website_broken_urls instead.

## Parameters

| Name | In | Type | Required | Description |
|------|----|------|----------|-------------|
| `website_id` | path | string | yes | UUID of the website. Get ids from list_websites. |
| `from` | query | string | no | Start of the window, YYYY-MM-DD or an ISO timestamp. Defaults to 7 days ago. Windows wider than 92 days are rejected, and data older than 7 days is sampled by the hosting layer. |
| `to` | query | string | no | End of the window, YYYY-MM-DD or an ISO timestamp. Defaults to now. |
| `group_by` | query | string | no | What to break the numbers down by. Defaults to path. |
| `limit` | query | number | no | Maximum rows to return, 1 to 500. Defaults to 50. |

## Request example

```bash
curl   "https://api.trustpager.com/functions/v1/api/v1/websites/:website_id/traffic"   -H "Authorization: Bearer YOUR_API_KEY"
```

---
Base URL: `https://api.trustpager.com/functions/v1/api/v1` — Auth: `Authorization: Bearer YOUR_API_KEY`