Skip to content
TrackPilot

Shopify

Add the script to your Shopify theme and send purchases with the server API.

A native Shopify app is on our roadmap. Until then, Shopify works with the script plus the server API.

1. Add the script to your theme

  1. Shopify admin → Online Store → Themes → … → Edit code.
  2. Open layout/theme.liquid and paste your install code right after <head>, above any Meta Pixel code.
  3. Save. PageView, ViewContent and AddToCart from your theme's pixel are now mirrored server-side.

Add your myshopify.com address as well as your own domain if customers can reach both (one site per domain, or use your main domain — subdomains are accepted automatically).

2. Purchases from the server

Shopify's checkout does not allow third-party scripts, so the browser often can't report the Purchase reliably. Send it from your server instead: subscribe to the orders/paid webhook (or use an automation tool) and forward the order to our server API with event_id: "purchase_<order id>", the customer's email/phone and the browser IP/user agent from the order.

If you also send a browser Purchase from the Shopify customer events pixel, give it the same eventID so Meta deduplicates.


Stuck? Ask for setup help — we answer in বাংলা or English.