Using facebook external_id with pixel and custom audience

8.2k views Asked by At

I am wanting to link visitors who have visited my website and then have performed an offline task up within a facebook audience. I have set up facebook pixel to push a external_id when a user visits my site based on the users user_id

e.g

fbq('init', pixel.id, {
        external_id: "35d3652b57be5238df572b6074a7794d966e3be78b19b32f712d060c8da202d6",
})

(https://developers.facebook.com/docs/marketing-api/server-side-api/parameters/user-data/)

I have then set up a custom audience (Customer List) which is the audience I want to use.

I later call the facebook api to add users to this custom audience based on their external_id

{audience_id}/users with schema EXTERN_ID and an array of external id's to add. (https://developers.facebook.com/docs/marketing-api/audiences/guides/custom-audiences/)

Every thing seems to work and I can see in my facebook audience history that 9000 rows were added but the size still says "Fewer than 1,000"

Is there something I am missing here when using external_id?

Thank you

2

There are 2 answers

3
juraj_frank_EXPONEA On BEST ANSWER

I was struggling with this one too. Try sending 'extern_id' in the pixel instead of external_id

fbq('init', '<YOUR_PIXEL_ID>', {
  'extern_id': <UNIQUE_ID_FOR_THE_CUSTOMER>
});

as per the documentation here

https://developers.facebook.com/docs/marketing-api/audiences/guides/custom-audiences/#external_identifiers

0
Igor Simic On

external_id - is representing unique user identifier, it should be sent on every event you fire the pixel - same value per user. The purpose of the external_id is to tell Facebook / Meta that all events you sent are coming from same user, but FB does not know which user is that based on that id. FB match the users (for audiences) based on fbclid or advanced matching, here you can find what is the logic behind it:

https://floyk.com/en/post/how-does-fb-google-tiktok-click-ids-works-and-why-is-important

https://floyk.com/en/post/setup-facebook-advanced-matching-for-websites