# What is RFM Analysis and How to Calculate RFM Scores

> RFM analysis segments customers by Recency, Frequency, and Monetary value. How to calculate the score, build segments, and apply it.

Source: https://www.erathos.com/en/blog/rfm-analysis
Em português: https://www.erathos.com/blog/rfm-analysis
Published: 2026-08-19
Category: Business Intelligence & Analytics

![RFM customer segmentation diagram with quadrants by recency, frequency, and monetary value](https://cms-media.erathos.com/RFM Analysis.png)

Many companies struggle to identify who their best customers actually are. Usually they look at just one metric, which ends up summarizing customer behavior in a superficial way.

That's where one of the key marketing analyses for data-driven companies comes in: RFM analysis. By gathering three metrics, you can segment your customers into distinct groups and work with each one according to its own characteristics.

This method is flexible. There's no single correct recipe for applying it. It's important to factor in your own business requirements, adapt it to each situation, and even evolve the method to match the company's needs over time.

### Where does this data actually come from?

Before you can calculate anything, you need clean, centralized data: order history, purchase dates, and customer IDs, usually scattered across an e-commerce platform, a CRM, and an ERP. If those systems don't talk to each other, RFM stays a spreadsheet exercise that goes stale the moment someone updates a price table or a customer record somewhere else. Most teams that get real, ongoing value from RFM have already solved that ingestion problem, moving order and customer data into a warehouse on a schedule, not something they will assemble manually. We'll come back to that at the end.

### What will you learn here?

- What RFM is and what it's for
- How to calculate each of the three metrics
- How to turn those metrics into an RFM score using quartiles
- How to segment customers into named classes, with a worked example from raw data to final segment

## What is RFM and how does it work?

RFM analysis is a method that uses three metrics to classify customers by consumption profile, so you can work each customer differently, win-back campaigns, promotions, cross-sell, depending on their class. Each customer gets their own RFM "score": we evaluate them on three metrics and assign a grade for each, on a scale of 1 to 4.

There are two parts to this: first, we gather the raw metric values for each customer (their actual recency, frequency, and average order value). Second, we translate those raw values into a 1–4 score by comparing each customer against the rest of the base. So we end up working with both an RFM value and an RFM Score, as in the tables below.

**Raw RFM values per customer**

Client

R (days since last purchase)

F (days between orders)

M (average order value)

00001

549

40

$275.00

00002

207

15

$345.01

00003

6

2

$229.21

...

...

...

...

**Scored RFM and resulting class**

Client

R score

F score

M score

RFM Score

Class

00001

2

2

3

2-2-3

Dormant occasional

00002

3

3

3

3-3-3

Potential champion

00003

4

4

3

4-4-3

Champion

...

...

...

...

...

...

Notice anything? The lower the raw recency and frequency values, the _higher_ the score. We'll get to why below.

RFM stands for three terms, and each one is one of the three metrics we evaluate:

**R - Recency**: how recently the customer made their last purchase.

**F - Frequency**: how often this customer buys. Are they an occasional buyer or a loyal one?

**M - Monetary**: usually understood as the customer's total spend, but we'll use average order value instead. Here's why: imagine a customer who made 10 purchases with an average order value of $1,000, totaling $10,000. A second customer made 2 purchases averaging $5,000, also totaling $10,000. If we used total spend, only frequency would tell those two customers apart, we'd lose the fact that one buys often in small amounts and the other buys rarely in large ones. Average order value keeps that distinction visible.

As with the segmentation itself, there's no single correct way to pick these metrics. What matters is asking whether a given metric makes sense for your business, and whether it might distort results when combined with the others.

## Calculating each metric

#### Recency

Two inputs: the current date and the date of the customer's last purchase. Recency is simply today's date minus the last purchase date.

Client

Last purchase date

Current date

R (recency, days)

00001

09/01/2019

03/03/2021

549

00002

08/08/2020

03/03/2021

207

00003

02/25/2021

03/03/2021

6

#### Frequency

Frequency is the number of events (orders) within a given time interval. We flip the usual numerator and denominator so the number is more intuitive, it's easier to read "3.66 days between purchases" than "0.28 purchases per day."

Formula: **F = (d1 − d0) / P**

- **P** = number of distinct orders placed
- **d1** = current date
- **d0** = date of the customer's first purchase

The interval is the time the customer has actually been active, from their first purchase to today, divided by how many orders they placed in that window.

#### Monetary (average order value)

Average order value is already a familiar metric: total revenue from that customer divided by their number of orders.

## We have the data. Now what?

With just the raw R, F, and M values, you already have enough to start exploring: plotting customer counts by segment, or relating two metrics to each other to see how your base actually behaves.

![chart\_customers\_by\_macro\_rfm-1.png](https://cms-media.erathos.com/chart_customers_by_macro_rfm-1.png)

_Customer count by macro RFM group._

![chart\_ticket\_vs\_frequency\_regular-1.png](https://cms-media.erathos.com/chart_ticket_vs_frequency_regular-1.png)

_Average order value vs. frequency across the Regular macro group's subsegments. This is exactly the kind of view that flags where a "hibernated" pocket of customers is sitting before it fully churns._

Before we turn raw values into scores, it helps to understand the statistic behind it: quartiles. If you already know quartiles, skip to the next section.

### A quick refresher on quartiles

When a sample is sorted in ascending order, you can split it into equal parts, as many as you like. For RFM we use **quartiles**: four equal parts.

A quartile is the cutoff value that marks where one equal-sized group ends and the next begins, similar to a cutoff score in an admissions process. Take a group of 12 students and their ages:

**Unsorted**

Student

Age

Amanda

19

João

18

Pedro

20

Marcos

21

Mateus

20

José

24

Lúcia

27

Antônio

23

Maria

21

Lorranie

22

Ana Clara

23

Lucas

26

**Sorted ascending**

Student

Age

João

18

Amanda

19

Mateus

20

Pedro

20

Maria

21

Marcos

21

Lorranie

22

Ana Clara

23

Antônio

23

José

24

Lucas

26

Lúcia

27

The quartile boundaries are the average of the values on either side of each cut point: **Q1 = 20**, **Q2 = 21.5**, **Q3 = 23.5**. That splits the group into four bands:

Band

Students

Ages

Q1 (25% lowest)

João, Amanda, Mateus, Pedro

18, 19, 20, 20

Q2 (25–50%)

Maria, Marcos

21, 21

Q3 (50–75%)

Lorranie, Ana Clara, Antônio

22, 23, 23

Q4 (25% highest)

José, Lucas, Lúcia

24, 26, 27

That's the whole mechanic. Now let's apply it to R, F, and M.

## Scoring R, F, and M with quartiles

Because a higher RFM score should always mean a _better_ customer, recency and frequency need to be scored in **reverse**. A customer who bought 2 days ago is better than one who bought 500 days ago, so the lowest quartile of recency (freshest purchases) gets the _highest_ score, 4. Same logic for frequency: since we're measuring days between orders, a smaller number means the customer buys more often, so it also gets scored in reverse. Monetary is scored normally: higher average order value, higher score.

Here's a 12-customer sample carried all the way through, sorted and scored for each metric:

**Recency (reverse-scored: lowest R → highest score)**

Client

R (raw)

R score

0005

2

4

0001

10

4

0002

24

4

0012

104

3

0003

430

3

0011

432

3

0010

765

2

0008

987

2

0004

1235

2

0009

1432

1

0006

1953

1

0007

3008

1

**Frequency (reverse-scored: lowest F → highest score)**

Client

F (raw)

F score

0001

4

4

0006

9

4

0005

34

4

0011

48

3

0012

64

3

0002

75

3

0004

76

2

0003

132

2

0008

255

2

0010

302

1

0007

432

1

0009

766

1

**Monetary (scored normally: highest M → highest score)**

Client

M (raw)

M score

0005

34

1

0010

49

1

0006

52

1

0007

67

2

0004

86

2

0008

97

2

0012

113

3

0009

116

3

0011

175

3

0002

196

4

0003

211

4

0001

233

4

### Putting it all together

Now we combine each client's three scores into one RFM Score and map it to a named segment (segments are defined in the next section):

Client

RFM Score

Segment

0001

4-4-4

Champion

0002

4-3-4

Potential champion

0003

3-2-4

Occasional

0004

2-2-2

Dormant regular

0005

4-4-1

Loyal

0006

1-4-1

Lost loyal

0007

1-1-2

Lost regular

0008

2-2-2

Dormant regular

0009

1-1-3

Lost occasional

0010

2-1-1

_Not in our taxonomy below_

0011

3-3-3

Potential champion

0012

3-3-3

Potential champion

> **A practical gotcha:** client 0010 landed on 2-1-1, a combination that doesn't fall cleanly into any of the named segments below. With 4 scores across 3 metrics, there are 64 possible combinations, and no taxonomy we've seen names all 64. Build a simple fallback rule for the leftovers (for example, default to the segment matching the customer's R score alone) so no customer silently falls out of your campaigns.

## Naming the segments

Once every customer has a score, you can assign a descriptive class to make the segment easy to act on. At Erathos, to meet a client's specific requirements, we built four broad classes with subclasses under each. You can adjust the boundaries and naming to fit your own business, this is the structure we suggest as a starting point.

### Champion

**Champion**: your best customers. They buy often, are active, and spend a lot. `4-4-4` · `4-4-3` · `3-4-4`

**Potential champion**: on track to be a champion, just hasn't hit peak frequency and recency yet. `4-3-4` · `4-3-3` · `3-4-3` · `3-3-4` · `3-3-3`

**Dormant champion**: a champion profile that hasn't purchased in a while. `2-4-4` · `2-4-3` · `2-3-4` · `2-3-3`

**Lost champion**: a champion profile that hasn't purchased in a very long time, sitting in the lowest recency quartile. `1-4-4` · `1-4-3` · `1-3-4` · `1-3-3`

### Loyal

**Loyal**: good, frequent, active customers, just not spending as much as champions. `4-4-2` · `4-4-1` · `4-3-2` · `4-3-1` · `3-4-2` · `3-4-1`

**Potential loyal**: falls short on either frequency or recency compared to a loyal customer (if both were high at once, they'd already be loyal). `4-2-2` · `4-2-1` · `3-3-2` · `3-3-1` · `3-2-2` · `3-2-1`

**Dormant loyal**: a loyal profile that hasn't purchased in a while. `2-4-2` · `2-4-1` · `2-3-2` · `2-3-1`

**Lost loyal**: a loyal profile that hasn't purchased in a very long time, lowest recency quartile. `1-4-2` · `1-4-1` · `1-3-2` · `1-3-1`

### Occasional

**Occasional**: doesn't buy often, but has a high average order value. `4-2-4` · `4-2-3` · `3-2-4` · `3-2-3` · `3-1-4` · `3-1-3`

**Dormant occasional**: occasional buyers who haven't purchased in a while. `2-2-4` · `2-2-3` · `2-1-4` · `2-1-3`

**Lost occasional**: high average order value, but hasn't bought in a very long time. `1-2-4` · `1-2-3` · `1-1-4` · `1-1-3`

### Regular

**Regular**: bought recently (active), but doesn't buy often and doesn't spend much. `4-1-2` · `4-1-1` · `3-1-2` · `3-1-1`

**Dormant regular**: low scores across the board; became inactive on top of already-low frequency and spend. `2-2-2` · `2-2-1` · `1-2-2` · `1-2-1`

**Lost regular**: the lowest overall scores, and the least active profile of them all. `1-1-2` · `1-1-1`

## Segment cheat sheet

Segment

Typical scores

Suggested action

Champion

4-4-4, 4-4-3, 3-4-4

Reward and retain: early access, loyalty perks, ask for referrals

Potential champion

4-3-x, 3-4-3, 3-3-x

Nudge toward champion status with frequency-based offers

Dormant / Lost champion

2 or 1 on R, high F/M

Priority win-back, personal outreach, understand what changed

Loyal

4-4-2, 4-4-1, 4-3-x, 3-4-x

Cross-sell and upsell, they're already engaged

Potential loyal

4-2-x, 3-3-x, 3-2-x

Frequency-building campaigns (subscriptions, bundles)

Dormant / Lost loyal

2 or 1 on R, mid F

Re-engagement email sequence before they fully churn

Occasional

4-2-4, 3-2-4, 3-1-4

Protect the relationship, these are high-value, low-touch customers

Dormant / Lost occasional

2 or 1 on R, high M

High-value win-back, worth a direct outreach given their spend

Regular

4-1-x, 3-1-x

Low priority for manual effort, good fit for always-on automation

Dormant / Lost regular

2-2-2, 1-2-x, 1-1-x

Low-cost automated nurture only, or exclude from paid campaigns

There are many valid ways to build this segmentation. If this exact model doesn't fit your business requirements, adapt the boundaries and class names with your team.

## Closing the loop

We hope this helped you understand and run an RFM analysis for your own customer base. The math itself is simple, quartiles and a bit of arithmetic, the real work is getting clean recency, frequency, and order-value data flowing from wherever it lives today (Shopify, an ERP, a CRM, a payments provider) into one place you can actually query and refresh on a schedule.

That's the layer Erathos handles: ingesting your order, customer, and revenue data from the tools you already use straight into your warehouse, so RFM (and everything downstream of it) runs on current data instead of a one-off export. [Start a free trial](https://app.erathos.com/?utm_source=blog&utm_medium=content&utm_campaign=analise-rfm&utm_content=cta-final-en) and get your first pipeline running today.
