# User attributes

Learn how to define an audience based on the user's attributes.

The [`user`](/reference/cql/context#user) variable gives you access to the [user's profile](/reference/user/overview), including interests, activities, statistics, and any custom attributes you have defined.

We store [interests](/reference/cql/data-types/user/user#user-interests-prop) and [activities](/reference/cql/data-types/user/user#user-activities-prop) as sets, so you do not have to worry about order or duplicates. To check if a user has a particular interest, you can use:

```cql
user's interest contains "marketing"
```

To check if a user has one or more specific interests, use the [`contains either`](/reference/cql/expressions/tests/collection/contains-either) test:

```cql
user's interests contains either ["marketing", "sales"]
```

To check if a user has all specified interests, you can use the [`contains all`](/reference/cql/expressions/tests/collection/contains-all) test:

```cql
user's interests contains all of ["marketing", "sales"]
```

Conversely, you can check if a user does not have any of the specified interests by using the [`contains none`](/reference/cql/expressions/tests/collection/contains-none) test:

```cql
user's interests contains none of ["marketing", "sales"]
```

Access to any other standard or custom attribute follows the same logic. For example, you can use the default attribute [`age`](/reference/cql/data-types/user/user#user-age-prop) to match young adults:

```cql
user's age is between 17 and 30
```

The same applies to custom attributes. Suppose you have a [custom attribute](/reference/cql/data-types/user/user#user-attribute-prop) called `score`. You can check whether the user's score is above a threshold using:

```cql
user's score is greater than 10
```

Or, if you prefer a shorter syntax, you can also write:

```cql
user's score > 10
```

For more information on user variables, see the [User](/reference/cql/context#user) section.
