# ccp analytics



{/* Generated by scripts/sync-cli-reference.ts */}

Show an App's web analytics (visitors, pageviews, bounce rate)

```text
Usage: ccp analytics [OPTIONS] [APP_ID]
```

| Argument   | Type or values | Default | Parser environment variable | Description                                                                      |
| ---------- | -------------- | ------- | --------------------------- | -------------------------------------------------------------------------------- |
| --json     | flag           | false   | —                           | Emit structured JSON on stdout                                                   |
| app\_id    | text           | —       | —                           | App ID (falls back to the active project config)                                 |
| --app      | text           | —       | —                           | Select the App explicitly by ID                                                  |
| --period   | text           | 7d      | —                           | Time window: 24h, 7d, 30d or 90d                                                 |
| --by       | text           | —       | —                           | Top-10 breakdown by one dimension: url, referrer, browser, os, device or country |
| --help, -h | flag           | —       | —                           | Print help                                                                       |

## Example [#example]

```bash
ccp analytics --period 30d --by url
```

## Global options [#global-options]

Set `CCP_CONTEXT` to choose a named context. An explicit `--context` takes precedence. See [organization selection](/docs/ccp/organizations) for organization defaults.

| Argument  | Type or values | Default | Parser environment variable | Description                                         |
| --------- | -------------- | ------- | --------------------------- | --------------------------------------------------- |
| --context | text           | —       | —                           | Select a developer context from \~/.ccp/config.toml |
