# Affinities

Affinities capture visitor interests in categories, brands, and products. Use affinities to understand what visitors care about and personalize their experience.

<figure><img src="/files/Wk6NHYjJiJOHbIXB4zOM" alt=""><figcaption></figcaption></figure>

## What affinities do

Affinities track visitor interest levels in different areas. AdaptiveCX calculates affinity scores based on:

* Pages viewed
* Time spent
* Interaction depth
* Recency of activity

## Affinity types

### Category affinities

Interest in product or content categories. Examples:

* Electronics
* Women's clothing
* Home & garden
* Sports equipment

### Brand affinities

Interest in specific brands. AdaptiveCX detects brands automatically from:

* Product pages visited
* Brand pages viewed
* Brand searches

<figure><img src="/files/W3b4kPfJwSKAD8carWdW" alt=""><figcaption></figcaption></figure>

### Color affinities

Interest in color preferences. Useful for:

* Fashion retailers
* Home decor sites
* Any visual commerce

<figure><img src="/files/PIbE6m3IsGsurguM7Sa8" alt=""><figcaption></figcaption></figure>

### Custom affinities

Define your own interest areas:

* Specific product lines
* Content topics
* Price ranges

<figure><img src="/files/gJwomdfvDSQVvemPu3uc" alt=""><figcaption></figcaption></figure>

## Active vs suggested affinities

* **Active affinities** - Categories and brands you've confirmed for tracking
* **Suggested affinities** - Affinities AdaptiveCX detected from visitor behavior

Review suggested affinities to discover interest areas you might not have considered.

## Create a category affinity

{% stepper %}
{% step %}

### **Open affinities**

Go to `Core` > `Affinities` and select the **Category** tab.
{% endstep %}

{% step %}

### **Create new category**

Click **Create New Category**.
{% endstep %}

{% step %}

### **Name the category**

Use clear category names:

* "Running shoes"
* "Cookware"
* "Mystery novels"
  {% endstep %}

{% step %}

### **Define detection rules**

Set how AdaptiveCX identifies interest:

* URL patterns: `/products/running-shoes*`
* Page content keywords
* Product category mapping
  {% endstep %}

{% step %}

### **Save and activate**

Click **Save** to start tracking affinity.
{% endstep %}
{% endstepper %}

## Create a custom affinity

{% stepper %}
{% step %}
**Select custom tab**

Go to `Core` > `Affinities` and click **Custom**.
{% endstep %}

{% step %}
**Click Create New Custom Affinity**
{% endstep %}

{% step %}
**Name your affinity**

Describe the interest area:

* "Budget-conscious shoppers"
* "Premium product seekers"
* "Sale hunters"
  {% endstep %}

{% step %}
**Set detection criteria**

Define what indicates this interest:

* URL patterns
* Price ranges viewed
* Specific product attributes
* Behavior patterns
  {% endstep %}

{% step %}
**Save the affinity**
{% endstep %}
{% endstepper %}

## Affinity scores

Each visitor receives an affinity score for each tracked area:

* **0-20%** - Low or no interest
* **21-50%** - Moderate interest
* **51-80%** - Strong interest
* **81-100%** - Very strong interest

Scores update in real-time as visitors browse.

## View affinity analytics

Each affinity shows:

* **Visitor percentage** - Portion of visitors with affinity
* **Visitor count** - Number of visitors
* **Trend** - How affinity popularity changes

## Use affinities

### In audiences

Create segments based on interests:

* Visitors interested in "Electronics"
* Visitors interested in "Nike" brand
* Visitors interested in multiple categories

### In adaptive experiences

Personalize based on affinities:

* Show relevant products in carousels
* Highlight preferred brands
* Filter search results by interest
* Tailor content recommendations

### In predictions

Include affinities as prediction features:

* Visitors interested in premium products more likely to convert
* Brand affinity predicts purchase category

## Affinity best practices

### Start with categories

Category affinities provide the broadest value:

* Cover major product areas
* Work for most sites
* Easy to align with navigation

### Add brands strategically

Don't track every brand. Focus on:

* Top revenue-driving brands
* Brands with loyal customers
* Brands you actively promote

### Review suggestions regularly

Suggested affinities reveal visitor interests you might miss. Check monthly to find new opportunities.

### Keep categories distinct

Avoid overlapping categories that confuse affinity detection:

* Good: "Men's shoes" and "Women's shoes"
* Avoid: "Shoes" and "Running shoes" (overlap)

## Confirm suggested affinities

To add a suggested affinity to active tracking:

1. Go to **Suggested Affinities** tab
2. Find the affinity in the list
3. Click **Add** to confirm it

AdaptiveCX moves it to active affinities and starts calculating scores for all visitors.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.abtasty.com/adaptivecx/getting-started/core/affinities.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
