With recently introduced feature of GTM, server side tagging and it’s known benefits, I want to move my Facebook pixel browser code on server. So I am looking for equivalent of Facebook pixel for server side tagging.
The closest thing I found is Facebook Conversion api but not exactly same.
Would like to hear other views on how they are achieving this
2
Answers
There are was no official Tag from Facebook for GTM Server Side. That’s why I created my own https://github.com/gtm-server/facebook-tag
The tag sends the event data from the Universal Analytics/GA4 client to Facebook.
It developed exactly like an easy replacement for Facebook WEB pixel.
There are quite a lot to learn and work to do this.
You need to understand the Facebook pixel hit’s payload. Something like
https://www.facebook.com/tr/?id={{pixelId}}&ev={{event}}&dl={{Document location}}...
Assemble the payload and send it to your Server Side GTM.
Create
Client
in the Server Side GTM to receive the hit.Create
Tag
to dispatch the hit to Facebook.The Server-Side GTM is not supported the 3rd party cookie and it means that the Facebook will not recognize the user you send from Server-Side GTM.
Facebook report will only show the conversion or event amount.
Can’t use this for remarketing or attribution.