Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Choose the ingestion route based on what you mean by “website analytics”: use Cloudflare’s account or zone analytics for traffic Cloudflare already observes, Workers Analytics Engine for custom metrics emitted by Worker code, or Basin Pipelines when you need a buffered event stream that lands in R2 for downstream analysis. These are distinct products, not interchangeable ingestion settings.

How do I send website analytics to Cloudflare?

Start with the source and destination you need. Cloudflare’s account and zone analytics, and its GraphQL Analytics API, expose Cloudflare-collected traffic, performance, security, reliability, and product data. They do not provide a general endpoint for sending arbitrary browser events into a custom warehouse. For Worker-generated metrics, use Workers Analytics Engine (WAE). For a durable event pipeline and analytical files or tables in object storage, use Basin Pipelines with R2.

What you need Recommended route Key consideration
Cloudflare-collected requests and zone traffic Account or zone analytics, or the GraphQL Analytics API Data is based on traffic Cloudflare observes and associated product metadata. See Cloudflare Analytics.
Custom events or metrics emitted by Worker code Workers Analytics Engine Write data points with an ordered schema and one sampling index; high-volume data may be sampled. See the WAE quickstart and the WAE SQL API.
Durable clickstream ingestion to analytical files or tables Basin Pipelines with R2 sinks Supports HTTP or Worker ingestion, SQL transformations, and Iceberg, Parquet, or JSON outputs; Cloudflare documents availability on Workers Paid plans. See Basin Pipelines.

For a typical site, the decisive question is whether you want to analyze Cloudflare’s view of requests, record custom measurements inside a Worker, or retain and process a stream of events outside that analytics workflow.

How to write custom website metrics with Workers Analytics Engine

WAE is designed for custom analytics written by Workers and queried later. Cloudflare’s overview describes it as an analytics service with a Worker write API and SQL query API. The basic setup is a dataset binding, a call to writeDataPoint(), and a query against the resulting dataset.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
#1 Best Overall
Elebase USB to USB C Adapter for iPhone 18 Pro Max,USBC Car Charger Adapter
  • Read Before You Buy — No Video Output: These adapters support charging and USB 2.0 data transfer, but cannot transmit video signals. Except for standard USB webcams (which use USB data only), they are not compatible with HDMI/DisplayPort cables, video-capable USB-C hubs, or docking stations with video output.
  • Convert USB-A Ports to USB-C: Designed to connect USB-C earphones, cables, flash drives, card readers, and other USB-C accessories to standard USB-A ports. Plug-and-play with no drivers or software required.
  • Aluminum Alloy Housing: Built with a sturdy aluminum alloy shell that aids in heat dissipation and protects against daily wear and scratches. Designed to maintain a stable and secure connection.
  • Compact & Travel-Friendly: The ultra-compact design allows the adapter to stay plugged into your device without blocking adjacent ports or adding bulk, reducing wear and tear on your original USB ports.
  • 12-Month Warranty: Backed by a 12-month manufacturer warranty for peace of mind. Designed to meet strict quality control standards for reliable everyday performance.

1. Add a dataset binding to Wrangler

Define an analytics_engine_datasets binding in your Wrangler configuration, giving it a binding name and a dataset name. You use the binding name from Worker code as env.<BINDING>. Cloudflare says the dataset is created automatically on the first write after the binding is defined; you do not need to create it manually in the dashboard. See Cloudflare’s WAE quickstart.

2. Choose the dimensions and measurements

Call env.<BINDING>.writeDataPoint() with arrays whose positions have consistent meanings throughout your instrumentation:

Rank #2
Anker USB-C Hub, 5-in-1 USB Hub for Laptops, 4K HDMI Multiport Adapter
  • 5-in-1 USB-C Hub: Experience comprehensive connectivity featuring a Power Delivery input, two USB-A 2.0 ports, a USB-A 3.0 port, and an HDMI port. (Note: The USB-C power delivery input port is only for connecting an external wall charger to power your laptop and cannot power peripheral devices.)
  • 90W Pass-Through Charging: Achieve optimal charging with 90W pass-through power to your laptop, supported by a total input of 100W, with the hub reserving 10W for operational efficiency. (Note: Wall charger not included.)
  • Quick Data Transfers: Accelerate your productivity with rapid data transfers using a high-speed 5Gbps USB 3.0 port and two 480Mbps USB 2.0 ports.
  • 4K HDMI Display: Enhance your visual experience with a hub capable of delivering 4K resolution at 30Hz in both mirror and extend modes. Please note that this hub is compatible with MacBook (macOS 12 and newer), Windows 10 and 11, ChromeOS, and laptops equipped with DP Alt Mode and Power Delivery. Note: This device is not compatible with Linux.
  • What You Get: Anker USB-C Hub (5-in-1, 4K HDMI), welcome guide, 18-month warranty, and our friendly customer service.
  • blobs: string dimensions, such as page path or response status.
  • doubles: numeric measurements, such as request duration.
  • indexes: one string used as the sampling key.

Cloudflare’s example uses path and response status as blobs, duration as a double, and hostname as the index. Treat that as an example schema, not a requirement. The current quickstart says to provide only one index; multiple indexes cause the data point not to be recorded. The write call returns immediately while the runtime handles the write in the background.

Decide what questions the dataset must answer before selecting its dimensions. Avoid putting personal or sensitive identifiers into event dimensions without a separate privacy and data-governance review; the cited product documentation does not establish whether a particular collection is appropriate for your site.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #3
Sale
Anker USB C Hub, 7in1 Multi-Port USB Adapter, 4K@60Hz USBC to HDMI Splitter
  • Sleek 7-in-1 USB-C Hub: Features an HDMI port, two USB-A 3.0 ports, and a USB-C data port, each providing 5Gbps transfer speeds. It also includes a USB-C PD input port for charging up to 100W and dual SD and TF card slots, all in a compact design.
  • Flawless 4K@60Hz Video with HDMI: Delivers exceptional clarity and smoothness with its 4K@60Hz HDMI port, making it ideal for high-definition presentations and entertainment. (Note: Only the HDMI port supports video projection; the USB-C port is for data transfer only.)
  • Double Up on Efficiency: The two USB-A 3.0 ports and a USB-C port support a fast 5Gbps data rate, significantly boosting your transfer speeds and improving productivity.
  • Fast and Reliable 85W Charging: Offers high-capacity, speedy charging for laptops up to 85W, so you spend less time tethered to an outlet and more time being productive.
  • What You Get: Anker USB-C Hub (7-in-1), welcome guide, 18-month warranty, and our friendly customer service.

3. Query the dataset with the WAE SQL API

Send a SQL query in the body of a POST request to /accounts/<account_id>/analytics_engine/sql, authenticated with a bearer token. Cloudflare’s token instructions specify the Account → Account Analytics → Read permission. The API supports a FORMAT query option to select the response format. See the WAE SQL API documentation.

4. Make aggregation sampling-aware

WAE may sample high-volume index values on write or read. Inspect _sample_interval when aggregating sampled data: Cloudflare’s SQL examples use SUM(_sample_interval) for counts and sample-weighted formulas for sums and averages. Choose an index that fits the grouping and sampling behavior you need, and use the documented weighting approach rather than treating every returned row as an unsampled event.

Rank #4
Sale
UGREEN USB to USB C Adapter Combo 4-Pack, 10Gbps USB C Converter Space Gray
  • Dual Converters, Infinite Potential:Includes 2× USB C male to USB A female adapters and 2× USB A male to USB C female adapters. Perfect for a wide range of uses—tablets with Bluetooth keyboards, expand USB ports on macbook, and more. Two different converters for all your daily needs
  • Next-Level 10Gbps & 3A Charging: No more slow 480Mbps, this usb to usb c adapter has a transfer speed of up to 10Gbps, allowing you to do more transferring in less time. This usb adapter fits both USB A and USB C charger, supporting up to 3A fast charging
  • Upgraded Exquisite Craftsmanship: With an aluminum alloy housing and metal connector, the usbc to usb adapter is extremely durable and sturdy. Rigorously tested to withstand more than 10,000 times of plugging and unplugging, ensuring long-lasting performance
  • Broad Compatible: The usb c to usb adapter widely supports all USB C/ USB A devices like laptops, tablets, cellphones, car chargers, and phone chargers. Such as compatible with MacBook Pro/Air 2023/2022, Thunderbolt 4/3 Devices,Apple MagSafe Watch 9/8/7/SE/Ultra, iPad Pro 2022/2021, Samsung Galaxy S23/S20/S10, and iPhone 17/16/15 Pro. Plug and play
  • Please Note: To reach 10Gbps speed, keep the cable under 3.3 ft. For USB A Male to USB C adapters, try flipping the USB C connector. USB C Male to USB A adapters support bidirectional 10Gbps transfer within 3.3 ft
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

How do I ingest clickstream data into Cloudflare R2?

Use Basin Pipelines when your requirement is a stream-oriented ingestion path with buffering, SQL validation, filtering, transformation or enrichment, and durable outputs in R2. Cloudflare documents HTTP endpoint and Worker-binding ingestion, and sinks for Iceberg tables in Basin Catalog or Parquet and JSON files. Its documentation specifically identifies clickstream workloads as a use case.

  1. Choose the event source. Send events to a Basin HTTP endpoint or write them from a Worker using the documented binding.
  2. Define the pipeline processing. Configure the SQL operations needed to validate, filter, transform, or enrich incoming events.
  3. Select the R2-oriented sink. Choose Iceberg tables in Basin Catalog or Parquet or JSON files, according to how downstream systems will consume the data.
  4. Check current product limits and plan details. Basin’s documentation says the service is Generally Available and available on Workers Paid plans; consult its current documentation for limits and plan terms before designing around specific throughput, retention, or cost expectations.

Cloudflare updated the Basin Pipelines page on October 1, 2026, and states that Basin Pipelines is now Generally Available. The service was formerly called Cloudflare Pipelines; existing resources and configurations continue to work. Use the current Basin Pipelines name when following current documentation, while recognizing that older references may use the former name. See Cloudflare’s Basin Pipelines documentation.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Best Value
Anker USB C Hub, 5-in-1 USBC to HDMI Splitter with 4K Display
  • 5-in-1 Connectivity: Equipped with a 4K HDMI port, a 5 Gbps USB-C data port, two 5 Gbps USB-A ports, and a USB C 100W PD-IN port. Note: The USB C 100W PD-IN port supports only charging and does not support data transfer devices such as headphones or speakers.
  • Powerful Pass-Through Charging: Supports up to 85W pass-through charging so you can power up your laptop while you use the hub. Note: Pass-through charging requires a charger (not included). Note: To achieve full power for iPad, we recommend using a 45W wall charger.
  • Transfer Files in Seconds: Move files to and from your laptop at speeds of up to 5 Gbps via the USB-C and USB-A data ports. Note: The USB C 5Gbps Data port does not support video output.
  • HD Display: Connect to the HDMI port to stream or mirror content to an external monitor in resolutions of up to 4K@30Hz. Note: The USB-C ports do not support video output.
  • What You Get: Anker 332 USB-C Hub (5-in-1), welcome guide, our worry-free 18-month warranty, and friendly customer service.

Should I use Workers Analytics Engine or Cloudflare Pipelines?

Choose WAE for custom metrics written by Worker code and queried through its analytics API. Choose Basin Pipelines when the central need is to ingest, process, and deliver a stream of events into R2 for broader downstream analysis. WAE is an analytics dataset workflow; Basin is a pipeline-to-storage workflow.

Question Workers Analytics Engine Basin Pipelines
How do events enter? Worker code writes points using writeDataPoint(). Events arrive through an HTTP endpoint or Worker binding.
What is the primary output? A dataset queried through the WAE SQL API. R2-oriented Iceberg tables or Parquet or JSON files.
What processing model is documented? Write custom measurements and dimensions, then query them; sampling can affect high-volume data. Buffered streams with SQL validation, filtering, transformation, or enrichment.
Availability detail established by Cloudflare’s documentation The cited WAE pages describe setup and use; they do not establish a plan requirement here. The Basin page, updated October 1, 2026, says Generally Available on Workers Paid plans.

Which Cloudflare SQL API should you use?

Cloudflare has separate SQL interfaces that are easy to confuse. The Workers Analytics Engine SQL API is hosted at /accounts/<account_id>/analytics_engine/sql and queries WAE datasets. The account Analytics SQL API is a different endpoint with a different dialect; it addresses WAE datasets using events.analyticsEngine.<DATASET_NAME> and requires accountTag scope. Use the API that matches the dataset and query syntax in your implementation rather than assuming the two SQL routes are interchangeable. See the WAE SQL API and Cloudflare’s Analytics datasets documentation.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.