# Contact attributes

Reference for contact and event attributes in Pristo CX populations: the six types, limits, key rules, and where segments, messages and reports use them.

Contact attributes are the extra fields that Pristo CX stores on each contact of a population, such as city or customer tier. Event attributes are the details that come with an activity, such as branch or amount. An account admin or a program admin defines contact attributes in the **Population** tab under **Actions** > **Contact attributes**, and event attributes under **Actions** > **Events attributes** > **Attributes**.

## Summary

| Type | Up to, per population | Example value | Comparisons in segments and filters |
|---|---|---|---|
| **Text** | 5 | `Haifa` | **Equals**, **Not equals** |
| **Number** | 2 | `42`, `12.5` | **Equals**, **Not equals**, **Greater than**, **Less than**, **Greater than or equal**, **Less than or equal** |
| **Date** | 2 | `2026-10-21` | The same six as numbers |
| **Time** | 2 | `14:30` | The same six as numbers |
| **Date & Time** | 2 | `2026-10-21 14:30` | The same six as numbers |
| **Boolean** | 2 | `true`, `false` | **Equals**, with **Yes** or **No** |

The limits count contact attributes and event attributes separately, so a population can have 5 text contact attributes and 5 text event attributes. When a type reaches its limit, the type list in the dialog disables it.

## Keys and names

| Field | Rule |
|---|---|
| **Unique Identifier** | 1 to 50 characters: English letters (a to z, A to Z) and underscores, with no underscore at the start or the end. It must be unique in its list. The dialog ignores case when it compares keys. Imports and the API use the key. You cannot change it after you add the attribute |
| **Attribute Name** | 1 to 50 characters. The name people see in the app, for example Age. You can rename an attribute at any time |
| **Attribute Type** | One of the six types in the summary. You cannot change it after you add the attribute |

Event types follow the same key and name rules, and they have no type.

## Contact attribute values

- Values come from [Import contacts](https://docs.pristo.io/cx/populations/import-contacts), [Import activities](https://docs.pristo.io/cx/populations/import-activities) and the `contact.customFields` object of [Send an event](https://docs.pristo.io/cx/api/send-an-event).
- The contact's page lists the values under **Additional attributes**. You cannot type a value there, and **Add contact** has no attribute fields.
- An import or an event writes only the attributes it carries. An empty cell or a missing key keeps the current value, so an import cannot clear a value.
- Pristo CX trims each value and cuts it to 50 characters. A value that cannot be read as the attribute's type is skipped, and an import lists it as a warning.
- Booleans accept `true`, `false`, `1` and `0`, in any case. Write dates as `YYYY-MM-DD`.
- In imports and the API, keys match whatever their case.

## Event attribute values

- Values come from [Import activities](https://docs.pristo.io/cx/populations/import-activities) and the top-level `customFields` object of [Send an event](https://docs.pristo.io/cx/api/send-an-event).
- Pristo CX stores them with the activity as text and does not check them against the type.
- An event-based distribution can filter on them under **Trigger events**. The filter reads the value as the attribute's type, so a value that cannot be read that way, or a missing value, does not match. For a boolean, send `true` or `false`.
- In the API, an event attribute key must match exactly, including its case.

## Where attributes are used

| Where | Contact attributes | Event attributes |
|---|---|---|
| The segment on a distribution's **Samples** tab | Yes | No |
| The event filters of an [event-based distribution](https://docs.pristo.io/cx/distributions/event-based) | No | Yes |
| Variables in messages and reminders, with **Add variable** | Yes | No |
| **Columns** on the Responses page, and the response panel | Yes | Yes |
| [Exports](https://docs.pristo.io/cx/responses/export-responses) | Yes | Yes |
| Dashboard segmentation and filters | Yes | Yes |

A variable in a message is replaced with the contact's value when the message is sent. A contact without a value gets empty text in its place.

## Delete an attribute

Pristo CX deletes a contact attribute, an event type or an event attribute only while the population has no contacts. Once the population has contacts, the attribute stays, even though the list stops showing it until you reload the page.

## Related

- [Populations overview](https://docs.pristo.io/cx/populations/overview)
- [Import contacts](https://docs.pristo.io/cx/populations/import-contacts)
- [Import activities](https://docs.pristo.io/cx/populations/import-activities)
- [Choose who receives a distribution](https://docs.pristo.io/cx/distributions/sampling-and-rules)
- [Dashboards overview](https://docs.pristo.io/cx/dashboards/overview)
- [Glossary](https://docs.pristo.io/cx/glossary)
