Override _fbp and _fpc cookies (Facebook Conversion API tag)

It would be great to have an option to override the _fbp (as it’s done with _fbc cookie) value within the server tag configuration, possibly within the user data section. Currently, the _fbp cookie value is retrieved from the getCookieValues API and the eventData object.

You can do it in User Data section of the FB template. FBP is listed as Browser ID

1 Like

Confirming this is correct. See this post with screenshot that indicates _fbp == Click ID.

But it seems like you are stating that _fbp == Browser ID.

I wonder which is true? I’m just wondering! Thank you so much!

In that post, rather incorrectly named variables.

_fbp is browser id

_fbc is click id which is generated based on query parameter ‘fbclid’ when it is present in url (when clicking on meta ads it is added automatically).

1 Like

Thank you for the quick reply @Alex ! I appreciate it. I was wondering but this makes sense.

I have a follow up question. I am planning on sending _fbp to sGTM using the Data Tag in wGTM.

  • Do you think I should add a parameter in the Meta Facebook cHTML tag for _fbp as well?

My first thought is that the Meta Facebook tag will send the _fbp to Meta without adding this explicitly.

By explicitly sending _fbp to sGTM using Stape’s Data Tag, I will ensure the _fbp value that sGTM sends to Meta matches the _fbp that the custom HTML tag on wGTM sends to to Meta.

There is no need to send cookies to Meta manually. Both web tag and server tag will automatically pick up _fbc and _fbp cookies and send with each event.
Here it is important that the server container works in first party context (as well as in general for server side tracking), i.e. that for sGTM a subdomain of the main domain where the events take place is used.

A separate case is Shopify. Because there the tracking on checkout works in sandbox - there you need to pass cookies to the server in event’s payload. But for this purpose there is an option ‘send common cookies’ in the Data tag. Meta tag and all other tags developed by Stape automatically checkout the necessary cookies from payload Data tag events if this option is active.

In other cases this is not necessary, everything will be transferred and used automatically.

1 Like

This might sound like a rookie question…

One event happens on https://siteone.com

And the other event happens on https://othersite.com

The subbomain in Stape container is set to https://ssgtm.siteone.com

  • How is this handled?

  • Do you think that the mismatch on https://othersite.com is causing issues with cookies?

  • How can I fix that? Would I need to add another subdomain to the Stape container for https://ssgtm.othersite.com?

  • Then how would I add the https://ssgtm.othersite.com server_container_url to the GTM web container tags? Currently it’s only the Facebook tags we are working with so I am using the Stape Data tag on wGTM (because I love Stape) :heart_eyes:.

Thank you for your input. Do you think I should move this to a new thread?

For server side tracking to work correctly, it is mandatory that events work in first party context. That is, each event must send to its own subdomain for sGTM.
You can either use different server containers for this or use one and configure data mapping:

1 Like