fbp and fbc Parameters

When the Facebook pixel is installed on a website, and the pixel uses first-party cookies, the pixel automatically saves a unique identifier to an _fbp cookie for the website domain if one does not already exist.

When a user clicks on an ad on Facebook, the link sometimes includes a fbclid query parameter. When the user lands on the target website, if the website has a Facebook pixel that uses first-party cookies, the pixel automatically saves the fbclid query parameter to an _fbc cookie for that website domain. See About Cookie Settings For Your Facebook Pixel for information on first-party cookie settings.

We recommend that you always send _fbc and _fbp browser cookie values in the fbc and fbp event parameters, respectively, when available.

If the _fbc browser cookie is not available, either because there is no Facebook pixel running on the website or because first-party cookies are turned off, it is still possible to send the fbc event parameter if an fbclid query parameter is in the URL of the current page request.

The fbc event parameter value must be of the form: version.subdomainIndex.creationTime.fbclid

  • version is always this prefix: fb
  • subdomainIndex is which domain the cookie is defined on ('com' = 0, 'facebook.com' = 1, 'www.facebook.com' = 2). If you’re generating this on a server and not saving an _fbc cookie, use the value 1.
  • creationTime is the UNIX time since epoch in seconds when the _fbc cookie was saved.
  • fbclid is the value for the fbclid query parameter in the page URL.

Here’s an example of what the fbc value could look like (note that the fbclid portion is invalid):

fb.1.1554763741205.AbCdEfGhIjKlMnOpQrStUvWxYz1234567890