How it works
- You register a webhook via Shopify’s Admin API (REST or GraphQL), pointing the callback address at your Nango webhook URL.
- Shopify sends a POST request to that URL when the subscribed event occurs, signing it with
X-Shopify-Hmac-Sha256and including theX-Shopify-TopicandX-Shopify-Shop-Domainheaders. - Nango verifies the signature, matches the shop domain in
X-Shopify-Shop-Domainto the connection’ssubdomain, and forwards the event to your app.
Setup
1. Get your Nango webhook URL
In the Nango dashboard, open your Shopify integration and copy the Webhook URL.2. Register the webhook in Shopify
Registering a webhook for a topic requires the scope that grants read access to the underlying resource (for example,read_orders for orders/create). Add the scope to your Shopify integration’s Scopes field in the Nango dashboard and re-authorize the connection if it was created before the scope was added.
Shopify’s REST Admin API has been legacy since October 2024, and public (OAuth) apps created after April 2025 must use the GraphQL Admin API — the REST tab below still works for existing apps and for the API Key (custom app) auth mode, but prefer GraphQL for any new OAuth integration.
- REST API
- GraphQL
orders/create); the GraphQL enum uses the equivalent screaming-snake-case name (ORDERS_CREATE).
Webhook payload
The POST body is the raw resource as JSON — the same shape as the REST Admin API response for that resource, with a numericid (not a GraphQL global ID), regardless of whether you registered the webhook via REST or GraphQL. Example for orders/create:
Connection matching
Nango matches an incoming webhook to a connection using the shop domain in theX-Shopify-Shop-Domain header against the connection’s subdomain. No extra configuration is needed on the connection.
Signature verification
- Shopify (OAuth): Nango verifies
X-Shopify-Hmac-Sha256automatically using your integration’s client secret — no extra setup needed. - Shopify (API Key): set a Webhook Secret on the integration in the Nango dashboard, matching the secret configured when you subscribed the webhook, so Nango can verify the signature against it.
Handle the webhook
Once routed to a connection, you have two options:- Forward it to your app — Nango forwards the event to your webhook URL with connection attribution. See External webhook forwarding.
- Process it in a sync — run a sync when the webhook arrives using
webhookSubscriptionsandonWebhookin a sync script. See Real-time syncs.
Supported events
Nango can route any topic Shopify delivers, since routing only depends on theX-Shopify-Shop-Domain header. Common topics:
For the full list, see Shopify’s webhook topics reference.
Rollback strategy
To stop webhooks, delete the subscription using theid Shopify returned when you created it:
- REST: send a
DELETErequest to/admin/api/2025-01/webhooks/<id>.json. - GraphQL: call the
webhookSubscriptionDeletemutation with thatid.