Source: https://datafa.st/docs/api/website/analytics/funnel-results
Markdown source: https://datafa.st/docs/api/website/analytics/funnel-results.md
Description: Return step-by-step analytics for one active funnel.

# Get funnel analytics

`GET https://datafa.st/api/v1/analytics/funnels/{funnelId}`

Return step-by-step analytics for one active funnel.

## Request

### Authentication

- `df_` website API key for one website.
- `dft_` account token with `analytics:read`. Pass `websiteId` as a query parameter.


### Path parameters

| Parameter | Type | Description |
| --- | --- | --- |
| `funnelId` | string | Funnel ObjectId. The funnel must belong to the website and be active. |

### Query parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `startAt` | string | No | Sets the beginning of the reporting window. Use it when you want a specific date range instead of the endpoint default. Must be provided with `endAt`. Example: `startAt=2026-05-01`. |
| `endAt` | string | No | Sets the end of the reporting window. Must be provided with `startAt`. Example: `endAt=2026-05-21`. |
| `timezone` | string | No | Controls how dates are interpreted and how time buckets are grouped. Defaults to the website timezone. Example: `timezone=America/New_York`. |
| `filter_country` | string | No | Limits results to visitors from one or more countries. Operators: `is`, `is_not`. Use country names or codes. Example: `filter_country=US,Canada`. |
| `filter_region` | string | No | Limits results to visitors from a region or state. Example: `filter_region=California`. |
| `filter_city` | string | No | Limits results to visitors from a city. Example: `filter_city=San Francisco`. |
| `filter_device` | string | No | Limits results by device type. Useful for mobile vs desktop analysis. Example: `filter_device=mobile`. |
| `filter_browser` | string | No | Limits results by browser. Use this to compare browser-specific traffic or revenue. Example: `filter_browser=Chrome,Safari`. |
| `filter_os` | string | No | Limits results by operating system. Example: `filter_os=iOS,Android`. |
| `filter_referrer` | string | No | Limits results by referrer domain or normalized source. Example: `filter_referrer=Google`. |
| `filter_page` | string | No | Limits results to visitors who viewed a page. Operators: `is`, `is_not`, `contains`, `does_not_contain`. Example: `filter_page=contains:/docs`. |
| `filter_entry_page` | string | No | Limits results by first page in the session. Operators: `is`, `is_not`, `contains`, `does_not_contain`. Example: `filter_entry_page=/pricing`. |
| `filter_hostname` | string | No | Limits results by tracked hostname. Useful when one website tracks multiple hostnames. Example: `filter_hostname=app.example.com`. |
| `filter_goal` | string | No | Limits results to visitors who completed a specific goal. Example: `filter_goal=signup`. |
| `filter_utm_source` | string | No | Limits results by UTM source. Example: `filter_utm_source=google`. |
| `filter_utm_medium` | string | No | Limits results by UTM medium. Example: `filter_utm_medium=cpc`. |
| `filter_utm_campaign` | string | No | Limits results by UTM campaign. Example: `filter_utm_campaign=launch`. |
| `filter_utm_term` | string | No | Limits results by UTM term. Example: `filter_utm_term=brand-keyword`. |
| `filter_utm_content` | string | No | Limits results by UTM content. Example: `filter_utm_content=hero-cta`. |
| `filter_ref` | string | No | Limits results by the `ref` URL parameter. Example: `filter_ref=twitter`. |
| `filter_source` | string | No | Limits results by the `source` URL parameter. Example: `filter_source=newsletter`. |
| `filter_via` | string | No | Limits results by the `via` URL parameter. Example: `filter_via=partner`. |

## Response

Returns a JSON object with `status` and endpoint-specific fields.

### Response fields

| Field | Type | Description |
| --- | --- | --- |
| `data[].funnel.id` | string | Funnel ObjectId. |
| `data[].funnel.name` | string | Human-readable name for the resource or event. The exact meaning depends on the endpoint. |
| `data[].funnel.slug` | string | Funnel slug. |
| `data[].funnel.steps` | object[] | Configured funnel steps used for matching. |
| `data[].data[].id` | string | Step ID. |
| `data[].data[].label` | string | Step label shown in reports. |
| `data[].data[].value` | number | Visitors who reached this step. |
| `data[].data[].revenue` | number | Revenue attributed to this row or time bucket, in the website currency. Use it to see which time periods or dimensions influenced paid conversions. Revenue attributed to visitors who reached this step. |
| `data[].data[].conversionRate` | number | Percent of first-step visitors who reached this step. |
| `data[].data[].dropoffFromPrevious` | number | Visitors lost compared with the previous step. |
| `data[].metrics.totalVisitors` | number | Visitors who reached the first funnel step. |
| `data[].metrics.completions` | number | Number of times this goal was completed. This counts events, so one visitor can contribute more than one completion. |
| `data[].metrics.overallConversionRate` | number | Percent of first-step visitors who completed the funnel. |
| `data[].metrics.overallRevenuePerVisitor` | number | Revenue divided by first-step visitors. |
| `data[].metrics.timezone` | string | Timezone used to interpret dates and group analytics buckets. Defaults to the website timezone. |
| `data[].metrics.startAt` | string|null | Start of the reporting window. Use it with `endAt` to query a specific date range instead of the endpoint default. |
| `data[].metrics.endAt` | string|null | End of the reporting window. Must be paired with `startAt` so DataFast can build the date range. |
| `data[].metrics.lastUpdated` | string | Response generation timestamp. |

### Errors

Common errors include `400` for invalid input, `401` for missing or invalid tokens, `403` for missing permission or suspended tracking, `404` for missing resources, and `500` for server errors.

## Code examples

### Example request

```bash
curl -X GET "https://datafa.st/api/v1/analytics/funnels/{funnelId}" \
  -H "Authorization: Bearer df_xxx"
```

### Success response

```json
{
  "status": "success",
  "data": [{
    "funnel": {
      "id": "665f0b3c4d2e1a0012345678",
      "name": "Signup funnel",
      "slug": "signup-funnel",
      "steps": []
    },
    "data": [{
      "id": "landing",
      "label": "Landing",
      "value": 1000,
      "revenue": 2400,
      "stepIndex": 0,
      "stepType": "pageview",
      "conversionRate": 100,
      "dropoffFromPrevious": 0
    }],
    "metrics": {
      "totalVisitors": 1000,
      "completions": 214,
      "overallConversionRate": 21.4,
      "overallRevenuePerVisitor": 2.4,
      "timezone": "UTC",
      "startAt": null,
      "endAt": null,
      "lastUpdated": "2026-05-21T00:00:00.000Z"
    }
  }]
}
```
