Filters

Pass Hashed Information for Facebook Advanced Matching

Overview

Facebook has a way for attribution providers and customers to send up hashed information about users to enhance how they do matching for attribution and analytics. With this data, Facebook can match conversion events to your customers to optimize your ads and build larger re-marketing audiences.

For more information, please see Facebook's document on Advanced Matching.

Fields Passed to Facebook

User DataParameterFormatExample
Emailem[email protected]
First NamefnLowercase lettersjohn
Last NamelnLowercase letterssmith
PhonephDigits only including country code and area code16505554444
External IDexternal_idAny unique ID from the advertiser, such as loyalty membership ID, user ID, and external cookie ID.[email protected]
GendergeSingle lowercase letter, f or m, if unknown, leave blankf
BirthdatedbDigits only with birth year, month, then day19910526 for May 26, 1991.
CityctLowercase with any spaces removedmenlopark
State or ProvincestLowercase two-letter state or province codeca
Zip or Postal CodezpDigits only94025
CountrycountryLowercase two-letter country codeus

Set Hashed Information for the SDK

Branch provides methods in our iOS and Android SDKs to set the hashed information to pass for Facebook Advanced Matching (set before initializing the SDK). Once set, this parameter is attached to install, open, and events until cleared or the app restarts.

...
//set hash parameters for Facebook Advanced Matching
Branch.getInstance().addFacebookPartnerParameter(withName: "em", value: "11234e56af071e9c79927651156bd7a10bca8ac34672aba121056e2698ee7088")
...
//initialize Branch session
Branch.getInstance().initSession(...)
Branch branch = Branch.getAutoInstance(getApplicationContext());
branch.addFacebookPartnerParameterWithName("em", "194b86d986ad041666822dad7602f1a7bac1d9e286273e86141666ffb4b1909b");