WooCommerce orders CSV export
A flat CSV of WooCommerce orders, from the Analytics > Orders export or a third-party order-export plugin. People assume a stable schema in the store's local time; the schema is exporter-dependent and the dates are stored in UTC.
The shape, how the file is really laid out
WooCommerce core ships a PRODUCT exporter, not an orders exporter, so the
orders CSV comes from Analytics or a plugin and its columns are NOT fixed
between installs. A common layout has order_id, order_number (which a plugin
may renumber independently of order_id), status with a "wc-" prefix
(wc-processing, wc-completed, wc-refunded, wc-on-hold, wc-pending, wc-cancelled,
wc-failed), order_total, order_subtotal, order_tax, order_shipping,
order_discount, payment_method, order_currency, and date_created. Some plugins
emit one row per order; others emit one row per line item and repeat or blank
the order-level money columns. WooCommerce stores timestamps in UTC/GMT in the
database and, depending on the exporter, emits either the GMT value or the
site-local value.
The traps
Status trap: only wc-processing and wc-completed are paid; wc-on-hold, wc-pending and wc-failed are unpaid and wc-cancelled is void, summing order_total across all statuses inflates revenue with money never collected.
- Every trap in this export, worked through
- The reconciliation anchor, the total the file asserts about itself
- The refusal cases, when to stop and ask instead of guess
Reference: WooCommerce documentation, order statuses · Analytics export · and date/timezone (GMT) storage (documentation)