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

# Shopify

> Understand Shopify orders, refunds, customers, and revenue in Datalyr.

The Shopify source sends commerce activity to Datalyr. Storefront tracking supplies the visit and campaign context used to attribute that activity.

## Before you start

Complete both parts of the Shopify installation:

* Connect the permanent `myshopify.com` domain in **Sources**
* Install the Web Pixel and enable the Datalyr App Embed

See [Install on Shopify](/installation/shopify) for the full installation flow.

## What Shopify sends

Datalyr records activity for:

* Paid, fulfilled, cancelled, and refunded orders
* Completed and abandoned checkouts
* New customers
* Order value, discounts, taxes, shipping, and currency when supplied
* Product and line-item details available in the Shopify event

Reports expose Shopify metrics including gross revenue, net revenue, refunded value, paid orders, average order value, customers, first-time and repeat orders, discount usage, and completed checkouts.

## How attribution works

The browser visit and Shopify order must share enough identity to form one journey. The App Embed captures the landing page, UTMs, click IDs, and visitor ID. The Shopify install carries supported identity into checkout and the order webhook supplies customer and transaction data.

<Warning>
  A connected store can send orders while storefront tracking is incomplete. Revenue will appear, but those orders may not have the original campaign or click ID.
</Warning>

## Verify a paid order

1. Open the storefront in a private browser window with test UTMs.
2. Confirm the landing `pageview` in **Events**.
3. Complete Shopify's supported test-payment flow.
4. Find the paid order event and confirm its order ID, value, and currency.
5. Open the customer in **Users** and confirm the storefront visit and order share a journey.
6. Refund the test order and confirm the refund arrives before validating net revenue.

## Avoid duplicates

Do not keep a manually pasted Datalyr web snippet when the App Embed owns storefront tracking. Do not also send the same Shopify order through custom server code unless both paths use a verified shared deduplication ID.

## Common issues

* **Orders but no attribution:** enable and save the App Embed, then test with a new order.
* **Storefront but no checkout events:** install the Web Pixel from the Shopify source.
* **Store domain rejected:** use the permanent `myshopify.com` domain without a protocol or path.
* **Refund totals differ:** compare the same timezone, currency, and refund processing period.
