Analytics & Diagnostics
Surge collects traffic analytics for every project at the edge—no script tag, no cookie banner, nothing added to your pages—and renders them right in the terminal. Four commands cover the questions you actually ask, and three more help you diagnose what the CDN is doing.
Traffic
surge traffic example.com
The overview: a bar chart of unique visitors across the last two weeks, visits and connections with day-over-day deltas, the share of traffic arriving encrypted, cache hit rates—plus the day's most-visited pages, 404s, redirects, and referring sources.
Audience
surge audience example.com
Who's visiting: browsers, operating systems, and device types, with counts.
Usage
surge usage example.com
Bandwidth: per-file bytes served today and yesterday, with a projected monthly total—so you can see exactly which assets are heavy before they become a problem.
Load
surge load example.com
Connection volume charted per datacenter across the network. Useful for understanding where in the world your traffic lands.
Diagnostics
files
surge files example.com
Lists every file in the live revision with its size—the manifest of exactly what the CDN is serving, as opposed to what's on your disk.
audit
surge audit example.com
Asks every edge node what it's serving for the domain: the revision, file count, total size, and the state of its SSL certificate. If a deploy or certificate seems inconsistent from where someone's sitting, audit shows you node by node whether the network agrees.
bust
surge bust example.com
Purges the project from the cache on every edge node, forcing the next request to fetch fresh content. Deploys invalidate correctly on their own, so day to day you shouldn't need this—it's the "make absolutely sure" lever, and it prints which nodes confirmed the purge.