On this page
What this issue is
An affiliate platform (for example Impact, PartnerStack, Rewardful or a similar tool) records a conversion when a customer buys. Along with the amount, it should receive a unique order ID. That ID is the key that links the affiliate's commission to one real order in your store or in Stripe.
This issue happens when the ID is missing, empty, a literal template tag such as {{order_id}}, the same value for every order, or a different ID from the one you use in Shopify or Stripe. The sale may still show up, but it cannot be matched.
Why it costs you leads or sales
Without a reliable order ID, you lose control of the money you pay out and the partners you rely on.
- Refunds and cancellations cannot be matched, so you pay commission on orders that were reversed.
- Duplicate conversions are not removed, because deduplication usually relies on the order ID.
- Partners dispute payouts, because neither side can prove which order a commission belongs to.
- Reports from the affiliate tool do not match Shopify or Stripe, so you cannot trust partner ROI.
- Good partners may leave if their sales look missing or wrong.
- Click on partner linkAffiliate cookie is set
- Customer paysOrder exists in Shopify or Stripe
- Conversion sentOrder ID empty or wrong
- Reconcile and refundCannot match to the order
- Correct payoutDisputes and overpayment
The sale is recorded, but the link back to the real order is broken.
How to check if your site has it
Open recent conversions in your affiliate tool
Look at the order or transaction ID column. Blank values, the same value repeated, or text with curly braces mean the ID is not being passed.
Compare with Shopify or Stripe
Pick three recent orders. In Shopify, note the order number and the order ID from the order URL. In Stripe, note the payment intent, charge or checkout session ID. Check whether any of these appear in the affiliate tool.
Place a test order through an affiliate link
Use a partner link or test link from your affiliate tool, then buy with Shopify bogus gateway or Stripe test mode. Do not use real card details for tests.
Inspect the conversion request
Open browser developer tools, Network tab, filter by your affiliate vendor name, and complete the order. Check the request payload for the order ID parameter and its value.
For server-side setups, check webhook logs
In Stripe, open Developers, Webhooks and look at the event payload and delivery response. In your affiliate tool, look for the received event and its ID field.
How to fix it
First decide which ID your affiliate tool expects, and use the same one everywhere. Shopify customers usually see the order number (such as #1001), while the system also has an internal numeric order ID. Stripe has several IDs. Pick one, keep it consistent and match what the tool documents.
Use the order status or checkout script area
In Shopify admin go to Settings, Checkout (or Customer events for pixels). Add the affiliate conversion code as a custom pixel or in the additional scripts area if your plan still has it.
Map the variable
In a custom pixel, read the order from the checkout_completed event: event.data.checkout.order.id for the order ID, and event.data.checkout.currency and totalPrice for value. Send them in the field your affiliate tool calls order ID.
Check the app
If you use the affiliate vendor's Shopify app, open its settings and confirm order ID mapping, then reinstall or update it if the field stays blank.
Send the ID from your server
For Stripe, listen to checkout.session.completed or payment_intent.succeeded in a webhook and pass the ID to the affiliate API from there. Server side is more reliable than the thank-you page.
Store the affiliate reference in Stripe metadata
Put the partner or referral ID in client_reference_id or metadata when creating the Checkout Session, so the webhook can read it later.
Replace placeholders with real values
Make sure template tags are rendered by your code before the call, not sent as literal text.
Create a data layer variable
Add a Data Layer Variable for the order ID, for example ecommerce.transaction_id, matching the name your site pushes.
Use it in the affiliate tag
Put that variable in the order ID field of the affiliate conversion tag. Fire only on the order confirmation event.
Preview and test
Use Preview mode, place a test order and check the variable has a value when the tag fires.
analytics.subscribe('checkout_completed', (event) => {
const checkout = event.data.checkout;
const orderId = checkout.order && checkout.order.id;
if (!orderId) return;
// Replace with your affiliate vendor's real conversion call
console.log('Send to affiliate tool', {
orderId: orderId,
amount: checkout.totalPrice.amount,
currency: checkout.currency
});
});Before
- Order ID blank or {{order_id}}
- Duplicates counted twice
- Refunds cannot be matched
After
- Real Shopify or Stripe ID on each conversion
- Duplicates removed by ID
- Refunds reverse the right commission
How to confirm it's fixed
Place a new test order via an affiliate link
Use test mode or a bogus gateway, never real card details.
Find it in the affiliate tool
The conversion should show the exact ID from the test order.
Reload the confirmation page
Check that no second conversion appears with the same ID, or that it is rejected as a duplicate.
Refund the test order
Confirm the affiliate tool reverses or flags the matching commission.
How to prevent it happening again
- Document which ID (order ID, order number, payment intent) each tool uses.
- Reconcile affiliate conversions against Shopify or Stripe every month.
- Retest after theme changes, checkout changes, app updates or a new payment method.
- Prefer webhook or server-side conversions for Stripe, as they do not depend on the browser.
- Keep the affiliate script and data layer under version control or change notes.
How FunnelGuard handles this
This issue is outside what FunnelGuard checks. Whether your affiliate platform receives the correct order ID and matches it to Shopify or Stripe records is a data reconciliation job. It needs your affiliate tool's reports or an order reconciliation and affiliate management tool, which compare real transaction records.
FunnelGuard is a synthetic monitoring service that runs your customer journeys on a schedule and checks steps, tracking hits and lead delivery. It can help with related checks, such as whether your funnel pages load, but it does not verify order IDs in your affiliate reports. A free read-only website audit is available if you want a broader look at your site.
Questions people ask
Why is my affiliate tracking not passing the order ID?
Usually the conversion code reads a variable that is empty on the confirmation page, or a template tag is sent as plain text. It can also be a Shopify app or Stripe webhook that does not map the ID field. Inspect the conversion request or webhook payload to see what is actually sent.
Which order ID should I send to my affiliate tool from Shopify?
Send the ID your affiliate vendor documents, and use it consistently. Shopify has a customer-facing order number and an internal numeric order ID. Either can work if the tool and your reports use the same one.
How do I pass a Stripe order ID to an affiliate platform?
Use a webhook such as checkout.session.completed or payment_intent.succeeded and send the session, payment intent or charge ID to the affiliate API. Store the partner reference in client_reference_id or metadata when creating the session, so you can read it in the webhook.
Why are affiliate conversions counted twice?
If the order ID is missing, the tool cannot tell that a reload or a repeated event is the same order. Passing a unique ID on every conversion lets most platforms discard duplicates.
Can I test affiliate order IDs without real payments?
Yes. Use Stripe test mode or Shopify's bogus gateway, and place the order through an affiliate link. Never use real card details for testing.
Does a missing order ID affect refunds and commissions?
Yes. Refund reversals usually match on the order ID. Without it, you may pay commission on refunded orders or need to correct payouts by hand.
Can FunnelGuard check if order IDs reach my affiliate platform?
No. That is outside what FunnelGuard checks. Use your affiliate tool's reports or a reconciliation tool that compares affiliate conversions with Shopify or Stripe orders.
Related issues
- TRK-259Affiliate tracking script missing (Impact, PartnerStack, Rewardful)Fix guide
- TRK-260Affiliate click ID (irclickid, ref) lost on redirectFix guide
- TRK-261Affiliate cookie not set or wrong domainFix guide
- TRK-262Affiliate conversion pixel missing on order confirmationFix guide
- TRK-263Affiliate conversion fires for every order including non-affiliateFix guide
- TRK-266Partner postback (S2S) failingFix guide