# Analytics

> See plan usage, bandwidth, storage, visits, top requests, cache, response codes, countries, and bot traffic for a site or for your whole account.

Source: https://docs.wpwaterfall.com/analytics

Analytics shows how your sites are used and how much of your plan they use. Open a site and choose **Analytics** for one environment, or choose **Analytics** in the main menu for every site on your account. Server bandwidth, CDN bandwidth, and storage are shared by all your sites, so the account page adds every site together and a site's page shows that site's part of the same allowance.

Pick a date range at the top right: the current or previous billing period, the last 24 hours, 7, 30, or 90 days, or a **Custom range** (UTC days, ending today at the latest, starting up to 13 months back). On a range of a day or two the charts show hours in UTC. The refresh button reads the newest numbers.

Most numbers come from your site's server log. The server counts each request, and WP Waterfall collects the totals every hour. A report with no data yet says **No traffic collected yet, come back soon.** A few reports read Cloudflare instead, for your site's own domains only.

## Reports

| Tab | What it shows |
|---|---|
| Plan usage | Server bandwidth, CDN bandwidth, and storage against your plan, then charts of visits, bandwidth, and storage. The bandwidth chart stacks CDN bytes on top of server bytes for each day. Point at a day to see how it compares with the day before. The account page lists each site once, with its live, staging, and preview environments under it, colored like the environment menu. Sort that list by visits, CDN bandwidth, disk space, or server bandwidth, and select the header again to flip the order. |
| Top requests | Three tables of the ten top paths, each with a download button. **Top requests by server bandwidth** ranks paths by the data your server sent, with the request count beside it. It ranks among each day's 50 most requested paths, so a rarely requested but very large file can be missing. **Top requests by views** ranks the same paths by requests. **Top requests by total bandwidth** would add Cloudflare's data for each path. Cloudflare reports that only on a paid plan, so the card says **Needs the Cloudflare Pro plan to work.** Bots and query strings are left out. |
| Cache | **Cache breakdown** stacks each day's requests by who answered them: the server cache (a page cache hit), the Cloudflare cache (answered by Cloudflare without asking your server), and not cached (a miss or bypass on the server). Cloudflare does not say which of its caches answered, so edge cache and CDN are one part, counted by whole UTC day, and a range of a day or two shows the server parts only. **Server cache component stack** and the **component chart** (a donut with the share of each) show hits, misses, and bypasses of the requests that reached the server. **Top server cache bypasses** lists the paths that ran PHP with no cached copy, most requested first, without query strings. Every card has a legend with counts, a tooltip on each bar and slice, and a download button. |
| CDN & edge | **CDN bandwidth** is the data Cloudflare sent to visitors for your domains, cached or not, as a line with a dot for each day. It is the figure that counts toward your plan. **Edge cache bandwidth** is the part Cloudflare answered from its cache without asking your server. Both come from Cloudflare, saved by whole UTC day, so an hourly range still shows days. **Top files by requests**, **Top files by bytes**, and **Top file extensions by bytes** say **Needs the Cloudflare Pro plan to work.**, because Cloudflare reports files and file types only on a paid plan. |
| Performance | Average response time and requests over time, PHP requests per minute, and the share of requests that ran PHP. For the slowest pages, see the Performance part of [Monitor](https://docs.wpwaterfall.com/monitor). |
| Response | **Response code breakdown**, a donut of the four classes (2xx success, 3xx redirect, 4xx client error, 5xx server error) with the total, the count, and the share of each. **Response stats**, four numbers: redirects, errors, the success rate (2xx and 3xx over all answers), and the error ratio (4xx and 5xx over all answers). A small error ratio is normal. Then three line charts, **500 error breakdown**, **400 error breakdown**, and **Redirect breakdown**, with a line for each exact code (404, 503, 301, and so on) and its count in the legend, and **Top 404 errors**, the paths that answered 404, ten rows. Each card has a download button. |
| Audience | Eight cards, each with a download button: **Top countries**, **Top browsers** (from Cloudflare) beside **Top cities**, **Top user agents**, **Top referrers** (full addresses, no query string), **Top ASN** (the network a visitor connected from), **Top client IPs** (each with a link that opens a public address lookup), and **Desktop vs. tablet vs. mobile**, stacked by day with the count and share of each. Bots are left out of every list; they are on the Bot traffic tab. A card whose source has sent nothing says **Not measured yet on this server.** |
| Bot traffic | **Requests**: every request that reached your server, stacked by day and class (Visitors, Named bots, AI crawlers, Automation tools), with a dropdown for one class. **Bot protection results**: what Cloudflare allowed and blocked each day. **Top traffic**: a dropdown for a traffic type and four tabs (**Top paths**, **Top user agents**, **Top countries**, **Top IPs**) with the ten top rows. Each card has a download button. |

Each chart and table has a download button for a CSV file.

## Google Search Console and Google Analytics

When you turn on the [Google Search Console](https://docs.wpwaterfall.com/connect-google-search-console) or [Google Analytics](https://docs.wpwaterfall.com/connect-google-analytics) tool for a site's live environment, the **Plan usage** report of the **Analytics** tab gets a section for each one, under WP Waterfall's own numbers, for the same dates. Google Search Console shows clicks, impressions, click through rate, average position, and the top queries and pages. Google Analytics shows users, sessions, page views, engagement rate, and the top pages and sources. Google's numbers come from Google and differ from the server's counts. The sections do not appear while the tools are off.

## How is a visit counted?

A visit is one visitor on one UTC day: the same IP address and browser count once, however many pages they open. The same address with a different browser counts again. Known bots, crawlers, uptime monitors, and command line tools do not count, and neither do their bytes. The **Bot traffic** tab shows them. Visits are one count for the whole account. They are a traffic figure, not a plan limit.

## Where does each number come from?

Most numbers come from the server log on your site's server: visits, server bandwidth, disk, page views, requests, top requests, referrers, the page cache report, response codes, response time, bot traffic, and top countries. A few come from Cloudflare, for your site's own domains only (your domains and your temporary `wpwaterfall.dev` names): CDN bandwidth, edge cache bandwidth, visits by domain, top browsers, and the Cloudflare part of the cache breakdown. WP Waterfall reads Cloudflare once an hour and saves one row per domain and day, so a day is a whole UTC day and the current day grows through the day. Cloudflare history starts on the day collection started.

Cloudflare numbers are estimates on busy periods, and WP Waterfall never shows a guess. When a report cannot show numbers it says why: **Cloudflare numbers are not available** (the read was refused; this is not a setting you can change, and nothing is billed from a figure that was not measured) or **Cloudflare does not offer this**. Query strings are cut from paths and referrers.

## What does the Audience tab keep about visitors?

The Audience lists describe your site's own visitors, so they are kept short and show only to people who can read your site's analytics.

- Each list keeps the top 20 rows of a day: user agents, cities, networks, client addresses, and device kinds. Referrers keep the top 50 as full addresses. Nothing is kept per request.
- **Client addresses are kept 30 days.** A range longer than 30 days shows the last 30 days of addresses. Every other list is kept 13 months.
- A **user agent** is cut to 200 characters. A **referrer** keeps the scheme, the domain, and the path: the query string and fragment are cut, and a path segment that looks like a secret shows as `:token`. A link from your own domain is not a referrer.
- **Cities and networks** come from Cloudflare, through the edge Worker, for requests that pass through it. A file Cloudflare serves by itself, and a page it answers from its cache, never reach your server, so no list here counts them. Countries, user agents, referrers, addresses, and devices count requests that reached your server.
- **Devices** are told apart by the user agent: an iPad that asks for the desktop site says it is a Mac, so it counts as desktop.
- The **IP link** opens a public lookup page (ipinfo.io) in a new tab. Nothing is sent until you follow it.

A day collected before this change has no lists, and its cards say **Not measured yet on this server.**

## How are bots told apart on the Bot traffic tab?

Classes come from what a request says about itself, in its user agent. They are not a score. The free Cloudflare plan has no bot score and no verified bot data, so there are four classes, and some traffic kinds are not measured.

| Class | What it holds |
|---|---|
| Visitors | Requests that do not say they are a bot: people, and bots that copy a browser. These cannot be told apart without a bot score, so they are one class. |
| Named bots | Search engines, monitors, link previews, and other crawlers that say what they are. They are not verified: a request that only claims to be Googlebot is counted here. |
| AI crawlers | A user agent on the shared Block AI crawlers list, such as GPTBot, ClaudeBot, and ChatGPT-User. A crawler that hides its name is not caught. |
| Automation tools | Scripts, command line tools, headless browsers, and requests with no user agent, such as curl, Python, Go, and HeadlessChrome. |

Not measured: **Excessive-rate AI crawlers** (the node keeps no rate per crawler), **Malicious traffic** as a class (requests Cloudflare stops never reach your server, so **Bot protection results** counts them as blocked), **Custom rules**, and **WP automations** (neither leaves a mark in the server log). The **Requests** chart counts requests that reached your server. Pages Cloudflare answers from its cache, and requests it blocks, are not in it.

**Bot protection results** counts, for each day, the requests Cloudflare saw. **Blocked** is an answer of 403 or 429, whoever sent it: a bot protection block or challenge at Cloudflare, or a refusal from your server. **Allowed** is every other answer. Cloudflare's free plan reports no security events, so the answer code is the measure, and a day before WP Waterfall started saving Cloudflare numbers has none.

**Top traffic** keeps the ten top rows of one type from each day's top lists: 50 paths of visitors a day, 10 of each bot class. Addresses are kept 30 days. A bot class's lists come only from days collected after this tab shipped.

## What do the response charts, the top 404s, and the PHP cards show?

- The **500, 400, and redirect breakdown** charts draw one line for each exact code the server sent, up to 64 different codes a day. At most six codes of a class get a line, and the others add up as **Other**. Their counts include bots, because every answer the server sent is counted.
- **Top 404 errors** lists the paths that answered 404 for visitors, most requested first, up to 50 a day. Known bots are left out. A path segment that looks like a secret is shown as `:token`.
- **PHP throughput** shows PHP requests per minute, and **PHP share** shows how many requests ran PHP against how many came from the page cache or static files.

A server that has not sent these counts yet shows **Not measured yet on this server.** on a chart card and **Not collected yet on this server.** on the top 404 card. The API views are `redirect-series`, `client-error-series`, `server-error-series`, `status-codes`, `top-404`, `php-throughput`, and `php-share`. The Caching page uses `top-cached-paths` and `top-bypassed-paths`: see [Clear all caches](https://docs.wpwaterfall.com/clear-caches#where-are-the-cache-numbers-and-the-purge-history).

## Usage and your bill

The Plan usage numbers are the same ones WP Waterfall uses for overage. Server bandwidth comes from the server log, CDN bandwidth from the saved Cloudflare days, and storage from the server's disk reading. See [Billing, usage, and overage](https://docs.wpwaterfall.com/billing-and-plans#how-usage-is-measured-and-billed).

## API

- `GET /v1/environments/{id}/analytics/usage` and `GET /v1/companies/me/analytics/usage` answer plan usage. Add `period=previous` for the whole previous billing period, or `from` and `to` for a range of your own. Each day has `bytes` (server) and `cdn_bytes` (null until Cloudflare has answered).
- `GET /v1/environments/{id}/analytics/{view}` and `GET /v1/companies/me/analytics/{view}` answer a report. `top-paths-bytes` ranks paths by bytes sent (unit `bytes`). `cache-series` and `response-series` return one row per time bucket and key (Hit, Miss, Bypass, or the status classes 2, 3, 4, and 5), for stacked charts. `edge-cache-bandwidth` answers the cached bytes of each saved Cloudflare day (unit `bytes`), or `available: false` with the note "Not measured yet on this server." when no saved day has the cache split. `top-user-agents`, `top-cities`, `top-asns`, `top-client-ips`, and `top-referrers` rank the Audience lists (a city key is `City|CC`, a network key is `7922|Name`), and `bot-classes` returns one row per day and traffic class (`visitors`, `named_bots`, `ai_crawlers`, `automation_tools`), and `bot-results` one row per day for `ALLOWED` and `BLOCKED`. `top-traffic-paths`, `top-traffic-user-agents`, `top-traffic-countries`, and `top-traffic-ips` take `traffic_type` (`all`, `visitors`, `named_bots`, `ai_crawlers`, or `automation_tools`, default `all`; any other value answers 422). `redirect-series`, `client-error-series`, and `server-error-series` return one row per day and exact status code of the class (three digit keys, at most six codes, the rest in `other`). `device-series` returns one row per day and device kind (`desktop`, `tablet`, `mobile`). They answer `available: false` with the note "Not measured yet on this server." when the node has not sent the list. `cache-breakdown` returns one row per bucket for `SERVER`, `EDGE`, and `NONE` (server cache, Cloudflare cache, and not cached); `EDGE` is left out when Cloudflare has not saved the cache split or the span is hourly. `status-codes` and `top-404` rank exact status codes and 404 paths, `php-throughput` answers PHP requests per minute for each bucket, and `php-share` answers PHP against static or cached requests. A view an older agent does not feed answers `available: false` with the note "Not collected yet on this server."

## Related

- [Billing, usage, and overage](https://docs.wpwaterfall.com/billing-and-plans)
- [View logs](https://docs.wpwaterfall.com/logs-viewer)
- [Monitor](https://docs.wpwaterfall.com/monitor)
- [Edge cache and CDN](https://docs.wpwaterfall.com/edge-cache)
- [Bot protection](https://docs.wpwaterfall.com/bot-protection)
