Skip to main content

Preparing Emails and Phone Numbers for Processing

The input data that you provide to the UID2 Service must be in the correct format so that the data is correctly converted to valid UID2s that you can use for targeted advertising.

This is true in all cases, whichever of these solutions you're using to convert your emails and phone numbers to UID2s:

  • By making direct calls to the UID2 APIs.
  • Via your own Private Operator.
  • By using any of the UID2 SDK integrations, Prebid.js integration, or Android/iOS integration.
  • By using Snowflake.

Processing Steps

The exact steps for preparing your data to be consumed by the UID2 service are laid out in the Normalization and Encoding documentation. The steps, in sequence, are as follows:

  1. Normalize the raw data.
  2. Create a 32-byte SHA-256 hash of the normalized raw data.
  3. Apply Base64-encoding to the 32-byte SHA-256 value.

If you're making direct calls to the UID2 APIs, or calling the UID2 APIs via your own Private Operator, you must complete each step, exactly as described and in the correct sequence.

Valid Input

If you're using a UID2 SDK, or other integration solution such as the Prebid.js integration, Android/iOS integration, or Snowflake, the options for your input data are shown in the following table.

Type of DIIInput FormatInstructions
EmailMust be one of the following:
  • Raw email
  • Normalized email
  • Normalized, then hashed, then base64-encoded
Email Address Normalization
Email Address Hash Encoding
Phone NumberMust be one of the following:
  • Normalized, including country code
  • Normalized, then hashed, then base64-encoded
Phone Number Normalization
Phone Number Hash Encoding