> ## Documentation Index
> Fetch the complete documentation index at: https://docs.abtestly.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Exports

> CSV of the results table for a stakeholder deck, or a raw-event dump for your own analysis. Both from the Export button on the results page.

The **Export** button on the results page opens a small modal with two
things you can do.

## CSV of the results table

Fast. Formatted for reading in a spreadsheet.

Four variants of the CSV:

* **Per goal**, one file per goal, per variant, with visitors and
  fires.
* **Aggregated**, one row per variant across all goals.
* **Daily**, one row per (variant, day) with cumulative visitors and
  fires.
* **Tabular**, one row per (variant, goal, day), the fullest shape,
  best for pivot tables.

Filenames are auto-generated from the experiment key, the goal, and
the report range, so a folder of exports stays organized.

## Raw event export

For anything the CSV table cannot answer, a custom join, a
segmentation the dashboard does not support, an audit, the raw event
export gives you every event on this experiment.

Formats: **CSV** and **JSONL**.

Because the file can be large, the export runs **asynchronously**:

1. Click **Export raw events** in the modal.
2. Pick a format.
3. ABTestly kicks off a background job. The modal shows the job's
   status: queued, running, ready, or failed.
4. When ready, download the file. The download link is valid for a
   while afterwards; the file itself is cold-stored.

If the file would be very large, the job may **truncate**. The modal
tells you the truncation point and how many events did not make the
file. In practice, truncation kicks in for experiments with tens of
millions of events; most exports come back complete.

## Where the raw event data comes from

The raw export reads from the [Exact Experiment
Ledger](/results/exact-ledger), not from Cloudflare Analytics Engine.
Every event you sent ABTestly, in the order it was received. Not a
sample.

Fields you get per row:

* Event id and timestamp.
* Site id, experiment id, variant key.
* Visitor id (a hash, not a raw identifier).
* Goal id if this is a goal event.
* Revenue and currency if this is a revenue goal.
* Order id if provided.
* Segment fields, device, browser, OS, country, source, entry path,
  UTM campaign, new-vs-returning.

## Refresh vs Export

**Refresh data** at the top of the results page recomputes the
verdict and metrics right now, using the latest events. Use it after
a burst of traffic, for example, right after a paid campaign launch.

**Export** captures the current view as a file. It does not recompute
first; if you want the very latest, hit Refresh and then Export.

## What Export does not include

* **PII.** No raw IP, no user agent string, no email, visitor id is a
  hash of a stable identifier, deliberately unlinkable to a person.
* **Draft or paused experiments.** Only running or archived
  experiments have exports.

## Programmatic export

The dashboard's Export button hits the same worker endpoints your own
code could call, `POST /api/experiments/:id/events/exports` to start
a job, `GET .../:jobId` to poll, `GET .../:jobId/download` to pull the
file. Auth is your Clerk session or a permanent API key from your
account settings. The full endpoint contract lives on the developer
reference; ask if you need it in this doc.
