viakite
Dashboard

Guides/Events and goals/Funnels

Funnels

See where people drop off between steps

A funnel is a path you want visitors to take, such as pricing page, then signup, then first purchase. Viakite counts how many visitors reach each step in order, and how many drop off between them, so you can see which step loses the most people.

How a funnel counts

A funnel has 2 to 10 steps. Each step is a page (a path, exact or with * for any part, such as /docs/*) or an event (a custom event's name).

A visitor counts at a step when they reached every step before it, in order, within 1 day of the first step. Other pages and events in between don't matter: a visitor who goes from /pricing to /blog and then signs up still passes from the first step to the second.

For each step you get:

NumberWhat it is
VisitorsVisitors who reached this step, in order
ConversionTheir share of the first step's visitors
DropThe share lost since the step before

Why 1 day, and 30 days for signed-in users

Without cookies, a visitor's id changes every day (see Privacy), so 1 day is the longest window Viakite can follow one visitor. A funnel that takes several days, such as signup then a purchase a week later, will read low.

For people your site identifies, a funnel can count users instead of visitors: one person, by your user id, across days and devices, with up to 30 days from the first step to the last. The visitor's anonymous events of the day they signed in count for them too. Visitors who never signed in are left out of a users funnel, so it suits steps that happen after sign-up, such as signup → first project → purchase.

Create a funnel in the dashboard

  1. Open Funnels

    Go to Analytics → Funnels and click New funnel. You need the analytics.manage permission.

  2. Name it and add the steps

    Give it a name, such as "Signup to paid". For each step pick Page or Event and enter the path or the event name. An event step can also take conditions on its properties: click Condition on a property and fill in the property, how it matches and the value, such as plan is pro. Click Add step for more, and use the arrows to change the order.

  3. Check the preview, then create it

    Once there are 2 steps, the drawer shows a preview over the date range of the page. Click Create funnel to save it.

Saved funnels show as tabs at the top of the Funnels page. The open funnel shows its steps as Bars or a Flow, for the date range and filters at the top of the page. Count switches between visitors within a day and signed-in users within 30 days. Use Split by to compare the same funnel by channel, source, campaign, country, device, browser, or new or returning visitors. Without cookies a visitor is known again only through identify: Returning is a visitor whose user id was seen before, and everyone else, anonymous visitors included, is New. The menu next to it has Edit steps and Delete; deleting a funnel keeps your data.

Next to each step's drop, the Bars view shows the median time from the step before, counted over the people who reached the step. Click a drop to see where those visitors went instead: for everyone who reached the step before and went no further, the first other page or custom event after it (a reload of the same page doesn't count), or Left the site when there was nothing after. It follows the same Count, date range and filters as the funnel.

With Compare on, each step shows its change against the comparison period (or the segment you compare with), and the line above the steps says how the funnel converted then. Below the funnel, the Breakdown card splits the visitors, visits, page views, bounce rate and events of the page's range and filters by any one or two dimensions, with its own Export CSV. It counts every visitor the filters keep, not only those in the funnel.

Funnels with the API

Saved funnels live on your region's data host, https://us.api.vk.viabio.me. Reading and running them needs analytics.view; saving, changing and deleting needs analytics.manage.

GET/v1/projects/{project}/funnels POST/v1/projects/{project}/funnels GET/v1/projects/{project}/funnels/{funnel} PATCH/v1/projects/{project}/funnels/{funnel} DELETE/v1/projects/{project}/funnels/{funnel}

Save a funnel:

terminal
1curl https://us.api.vk.viabio.me/v1/projects/prj_…/funnels \
2 -H "Authorization: Bearer sk_live_us_…" \
3 -H "Content-Type: application/json" \
4 -d '{
5 "name": "Signup to paid",
6 "steps": [
7 { "kind": "page", "page_path": "/pricing" },
8 { "kind": "event", "event_name": "Signup" },
9 { "kind": "event", "event_name": "Purchase" }
10 ]
11 }'

Then get its numbers for a date range, with optional filters and a split:

POST/v1/projects/{project}/funnels/{funnel}/results
terminal
1curl https://us.api.vk.viabio.me/v1/projects/prj_…/funnels/fnl_…/results \
2 -H "Authorization: Bearer sk_live_us_…" \
3 -H "Content-Type: application/json" \
4 -d '{ "date_range": { "preset": "30d" }, "split": "channel" }'

split takes a dimension's name (channel, utm_campaign, country…) or new_returning. count_by is visitors (the default) or users:

terminal
1curl https://us.api.vk.viabio.me/v1/projects/prj_…/funnels/fnl_…/results \
2 -H "Authorization: Bearer sk_live_us_…" \
3 -H "Content-Type: application/json" \
4 -d '{ "date_range": { "preset": "90d" }, "count_by": "users" }'

The answer lists each step with visitors (visitors, or users with count_by: users), conversion and drop (both in percent), median_seconds on every step after the first (the median time from the step before, among those who reached it; left out when nobody did), a splits list when you asked for one, the window used ("1 day" or "30 days") and count_by.

An event step can also have up to 20 conditions on the event's properties, each a property, an operator (is, is_not, contains, starts_with) and a value, such as { "kind": "event", "event_name": "Purchase", "conditions": [{ "property": "plan", "operator": "is", "value": "pro" }] }. The step then counts only events that pass all of them.

To try a funnel without saving it, send its steps to the run endpoint (it takes count_by too). Here a step is { "type": "page", "value": "/pricing" } or { "type": "event", "value": "Signup" }, with the same optional conditions on an event:

POST/v1/projects/{project}/analytics/funnel

To see where the people who stopped at a step went instead, send the step they reached (after_step, counted from 1, any step before the last) with the same date_range, filters and count_by:

POST/v1/projects/{project}/funnels/{funnel}/dropoff
terminal
1curl https://us.api.vk.viabio.me/v1/projects/prj_…/funnels/fnl_…/dropoff \
2 -H "Authorization: Bearer sk_live_us_…" \
3 -H "Content-Type: application/json" \
4 -d '{ "after_step": 1, "date_range": { "preset": "30d" } }'

The answer has visitors (how many reached that step and no further) and next, up to 20 places with the most visitors first, each a kind (page, event, or exit when nothing came after), a value (the path or event name, empty for exit) and its visitors.

What doesn't work yet

Gaps in funnels today

  • No 30-day window for anonymous visitors. Only a users funnel follows people across days; cross-session mode isn't built.
  • Median times and "where they went instead" are for the whole funnel, not for each split value, and only in the Bars view.

Next steps