Hi everyone,
I need expert advice on a tracking issue that started immediately after I installed the AfterSell app on my Shopify store.
Since adding the app, my reported ROAS in Meta has dropped significantly (showing 1.6 while my actual is 2.0). It seems the post-purchase upsell funnel is disrupting the standard tracking flow.
The Setup:
What’s happening:
-
Funnel Break: Before AfterSell, the customer went straight to the “Thank You” page. Now, they hit the upsell offer, and it seems the GTM Web Container either loses the session or fails to fire the final purchase event with the correct aggregated value.
-
Data Leak: My Shopify Customer Events (Pixel) shows a “not subscribed to any events” warning, even though the Stape CDN script is present.
-
Tag Placement: I’m also getting a “Tag not placed correctly / too low in the page” error in GTM, which I suspect is causing us to miss users who exit quickly after the initial purchase but before the upsell is processed.
Questions for the experts:
-
How do I properly “subscribe” to AfterSell events within the Shopify Pixels (Customer Events) sandbox so they are sent to my Stape Server?
-
Is there a recommended way to ensure the initial purchase and the post-purchase upsell are aggregated into a single purchase event before being sent to Meta CAPI?
-
Should I move my entire GTM implementation into a Custom Pixel to fix the placement issue and ensure it works during the AfterSell redirect?
I’m looking for a “bulletproof” way to make sure that no matter what apps I add to the checkout, the Server-side tracking captures the final transaction value from the server, not just the browser.
Thanks in advance!
This looks like the common AfterSell pattern on Shopify stores running GTM Web plus server-side. The Customer Events warning about no subscriptions can be expected in some Stape setups. Those analytics.subscribe calls live inside the JS file that gets downloaded, not in the snippet the admin inspector shows. It does not prove events are failing. Worth verifying in sGTM Preview or Stape logs to confirm.
The GTM error about the tag being placed too low is a symptom only. Even fixing that loading warning probably would not solve the revenue gap, because the value problem happens after the browser purchase event.
AfterSell inserts its offer page between checkout completion and the thank you page. The browser-side purchase event fires with the original order total. When the customer accepts the upsell, AfterSell updates the order on the server side. Your web container has already sent the pre-upsell number to Meta CAPI. If Meta is missing about 20% of final revenue, a real 2.0 ROAS can show up around 1.6.
Do not try to combine the initial purchase and upsell into a single browser event. The browser cannot reliably see the final total when post-purchase apps modify orders server-side. Keep the browser purchase event unchanged. It is still the cleanest place to preserve the original purchase attribution path, while the upsell delta should be handled separately server-side.
Route a Shopify orders/updated webhook into the server container instead. From there send a separate Meta CAPI event carrying only the upsell delta. Do not reuse the original purchase event_id. This is not a deduped copy of the same event, it is an incremental upsell. Give it its own event_id, and use a modified transaction reference like order123-upsell so you can reconcile later. Filter the webhook so it only fires when line items or the order total increase after the original purchase, and store the processed update ID so retries or later edits do not send duplicate upsell events.
Moving the whole setup into a Custom Pixel would create different problems. The Custom Pixel runs in Shopify’s sandbox, so the GTM dataLayer is isolated from the main page, GTM preview/debugging becomes harder, and Consent Mode becomes easier to misconfigure. That does not fix the upsell value problem.
If the missing value is really the upsell delta, reported ROAS should move closer to actual.