Meta Deduplication not working on PageViews

Hello,

Subject: META CAPI deduplication via sGTM
We are able to deduplicate Meta Events (excluding pageviews) :white_check_mark:
We are unable to deduplicate pageviews :cross_mark:

The sites concerned are SPAs: Single Page Applications, i.e., they do not actually “reload” pageviews each time the page is changed):
xxx.mon-site.org (x6, 1 per region)

We use GA4 (not the “Stape Data Tag”) to transfer data from GTM web to GTM server.

For GA4, in GTM web, we use official GA4 tags.
For GA4, in GTM server, we use official GA4 tags.

For Meta, in GTM web, we use “custom HTML” tags (not a template).
For Meta, in GTM server, we use Stape.io's “Facebook Conversion API” tags: 
1 in “Inherit from client” mode (Pageview)
2 in “Override” mode (Event 1 and Event 2)

We use the “Unique Event ID” variable from Stape.io

What we did in concrete terms
(screenshots available here: Issues META Deduplication — ImgBB)

• In GTM web:

  1. Added event_id to the Google tag (GA4) configuration settings
    “event id config parameters” image in ImgBB (link above)

    1. Added event_id to each GA4 Event tag
      “event id ga4 tags” image in ImgBB (link above)

    2. Modified the three Meta “Custom HTML” tags (Pixels, Event 1, Event 2) to add event_id
      “event id meta tags” image in ImgBB (link above)

• In GTM server:
1) Added event_id within the three META tags (“Facebook Conversion API”) from Stape
“event id meta gtm server” image in ImgBB (link above)

The problem?
For “GA4 Events” or “Meta Events,” NO problem :white_check_mark:

:red_exclamation_mark: For “GA4 Pageviews”:

Problem 1: Within the GTM server (only), the Event_ID remains the same between different pageviews, which is not normal; it should be different

Problem 2: From the second pageview onwards, between GTM web and GTM server, the Event ID is different, when it should be the same

:red_exclamation_mark:For “Meta Pageviews” :

Problem 1: Within GTM server (only), the Event_ID remains the same between different pageviews, which is not normal; it should be different

Problem 2: Between GTM web and GTM server, the Event ID is different, when it should be the same

How can we fix these issues, please?
Many thanks in advance,

Hi!
Is there anyone who could help us on this?
I’m also trying with the support but we can’t get it fixed for now.
It would help us a lot to know how to fix this issue so we can replicate it for all of our clients.
Thanks a lot in advance,

Hi,

The transport tags on the web should use the same triggers as correspondent facebook tags for them to share the same event_id.

Having event_id in “Google Tag shared event settings” is wrong as it modifies the general Gtag initialized on the website page and that`s exactly why the event_id stays the same for all subsequent events for your SPA website. You need to include it manually in the payload of each individual event to avoid this behaviour.

Hope it helps.

1 Like

Oleksii,
Thanks for your answer.

Actually, the event_id is not in “Google Tag: Shared Event Settings”
The event_id is in “Google Tag: Configuratin Settings”

Is that better? Or is it still wrong?

If it’s wrong, when you say “You need to include it manually in the payload of each individual event to avoid this behaviour.”, how can I do this (through GTM ideally)?

Thanks a lot in advance,

What i’ve tried (following some researches):

  • Add send_page_view = false in my GA4 tag in GTM web
  • Create a dedicated GA4 Event tag “page_view” in GTM web
  • Disable the box “Page changes based on browser history events” in GA4 advanced “Enhanced measurement” settings

It was supposed to fix this issue, but I’ve tried again, and nothing changed, I still have the same issues.

Do you have any idea?
Thanks in advance,

Another thing i’ve tried after some researches:

  • For my page_view tracking (GA4, Meta, Google Ads…) i was using a trigger History Source = pushState (+ consent)
    while
  • For my events tracking (GA4, Meta, Google Ads), i was using a more precise trigger: gtm.newUrl

So I tried adding a new condition in my page_view tracking triggers: gtm.newUrl is not equal to gtm.oldUrl

Those 2 variables works (= are not returning “undefined” after the 1st pageview) but it doesn’t fix my issue, I still have the event_id for all my GA4 page_views.

I really don’t understand how to fix this.
Can you please help?
Thanks in advance,