Build Basics

Best Practices for Collecting Information

If you collect, or plan to collect, personal information from users, it is critical that you handle that data responsibly.

Did you know?

Personal information includes obvious things like an email address, phone number, device identifier, physical location, and spending habits. But even less obvious information like zip code or typical commute time can be combined to help identify a person without their consent.

Only collect what you need
Permalink Get a link to this section

Collect the minimum amount of personal information necessary to provide the desired functionality. For example, if you only use email to communicate with site visitors, there is no reason to also collect phone numbers.

Always use opt-in instead of opt-out.
Permalink Get a link to this section

Let customers consent to sharing their data rather than collecting their data by default. For example, include a checkbox asking for permission to collect contact information and leave it unchecked by default.

Do not persist PII
Permalink Get a link to this section

Avoid persistent caching or storage of PII, including in logs. Do not keep the information for longer than you have to. The easiest way to avoid unintentionally exposing sensitive information is to delete it when you no longer need it.

Do not share PII
Permalink Get a link to this section

Avoid sharing any personally identifiable information (PII) or location information with third parties. When customers give you permission to collect and save their information, there is an expectation that the information will be kept safe and not be shared with others. Sharing their information with a third party without asking for explicit permission violates those expectations. You may be complicit should the third party handle the information irresponsibly.

Encrypt customer information in transit
Permalink Get a link to this section

Secure your website traffic with HTTPS and TLS. If you are unfamiliar with HTTPS and TLS, we recommend reading our TLS and HTTPS guide for more information.

Handle customer data responsibly
Permalink Get a link to this section

If your application uses customer contact information, be sure to use that information judiciously. Here are some tips on how to handle customer data responsibly:

  • Respect customer email preferences. If they have opted out of marketing emails, keep CustomerPreferences false.

  • Do not store personally identifying information (PII) like name, email, and physical address without explicit consent.

  • Do not store sensitive or payment info in the note field.

  • Always use secure HTTPS for your own services to protect user information in transit.