Two people in the same business can calculate net revenue retention for the same year and get answers fifteen points apart. Neither has made an arithmetic error. One included customers who signed up in March; the other converted euro contracts at today's rate; a third counted a returning customer as lost. Each choice is defensible on its own, and each one moves a figure that boards and investors look at closely.
This template sets out the NRR calculation and its gross counterpart in a form you can audit: the formula, the fields it needs, the rule for every awkward case, and a worked example where each rule is applied to real-looking numbers so you can see how much it matters.
The two formulas
Both measures start from the same place: a fixed group of customers who were paying you on the first day of the period, and the monthly recurring revenue (MRR) they were paying then. Nothing that happens to anyone outside that group counts.
| Measure | Formula | Can exceed 100%? |
|---|---|---|
| Net revenue retention (NRR) | (starting MRR + expansion − contraction − churn) ÷ starting MRR | Yes |
| Gross revenue retention (GRR) | (starting MRR − contraction − churn) ÷ starting MRR | No |
| GRR, per-customer form | Σ min(starting MRR, ending MRR) ÷ Σ starting MRR | No |
The definitions behind the terms:
- Expansion is any increase in a starting customer's MRR: more seats, more sites, an add-on, a price rise.
- Contraction is any decrease in MRR from a customer who is still paying something.
- Churn is the full starting MRR of a customer who is paying nothing at the end.
The per-customer form of GRR is the safer one to implement. It caps each customer at their own starting value, so one customer's upgrade can never hide another customer's downgrade. Chargebee's retention report documentation describes the same approach, telling users to take the minimum of beginning and end MRR when calculating GRR.
Notice what is not in either formula: new customers. NRR answers "what are last year's customers worth now compared with then?" If new business leaks into the numerator, the result becomes a growth rate wearing a retention label.
The data model
Fields you need
| Source | Record | Fields used |
|---|---|---|
| Billing system (Stripe, Chargebee or similar) | Subscription | customer, status, currency, items with price and quantity, start date, cancellation date, cancel-at-period-end flag |
| Billing system | Price | unit amount, billing interval and interval count |
| Your own table or CRM | Customer group | billing customer ID, parent group ID, date of any merger |
| Finance | Exchange rates | rate per currency at the period start date |
| Billing system | Invoice lines | used only to explain changes, never as the MRR value |
In Stripe these map to the Subscription object: customer, status, currency, items, start_date, canceled_at, ended_at and cancel_at_period_end. Each subscription item carries a price with a recurring.interval, which is how an annual price gets divided down to a monthly one.
The joins
| From | To | Join key | Notes |
|---|---|---|---|
| Subscription | Customer group | billing customer ID → mapping table | You maintain this; billing systems don't know that two accounts are one company |
| Subscription | Exchange rate | subscription currency + period start date | One fixed rate per currency for the whole calculation |
| Customer group (start) | Customer group (end) | parent group ID | The retention unit; compare snapshots, not event streams |
The mapping table is the one most teams skip, and it is the one that decides how mergers and multi-entity customers are treated. If your CRM account ID is stored on the billing customer (for example in a metadata field your team populates), use that as the key. If it isn't, the mapping has to be built and owned by someone, because there is no reliable automatic match between a billing account and a corporate group.
Rules for the awkward cases
The method that holds up best is a pair of snapshots: each customer group's normalised MRR at the close of the day before the period starts, and the same at the close of the last day. Everything below follows from that choice.
Customers who joined during the period
Exclude them entirely, even if they upgraded twice. They belong in a later cohort. A trailing-twelve-month NRR therefore only covers customers who were live twelve months ago, which is why it moves slowly.
Mid-period upgrades and downgrades
Only the ending MRR matters. A customer who upgraded in June and downgraded in September is measured on where they finished. Proration invoices raised at the moment of an upgrade are one-off charges and should never be read as MRR; they are why invoice totals are the wrong source for this calculation.
Reactivations
A starting customer who cancels and returns within the period is compared on start and end values like anyone else. If they came back on a bigger plan, that is expansion. Stripe's Billing analytics tracks reactivation as its own MRR movement, which is useful for a monthly roll-forward but means a flow-based sum will show the original cancellation as churn unless the return is netted off. A customer who left before the period began and returns during it is not in the cohort; treat them as new for retention purposes.
Currency
Convert both snapshots at the same rate, the one on the start date. That is constant-currency retention, and it stops a weakening euro from looking like customers paying less. Stripe's MRR growth definition carries a separate FX adjustment line for exactly this reason. If you also want to show the reported-currency figure, present it as a second line rather than mixing the two.
Annual prepay and notice periods
Divide annual prices by twelve; Stripe's own MRR example does the same with an annual plan. A customer who has given notice but whose paid term runs beyond the period end is still a paying customer on the last day. Be aware that Stripe's support article on MRR says a subscription set to cancel at period end stops counting at the time of the API call, so its figures will treat that customer as churned earlier than this rule does. Decide which you want and write it down.
Mergers of accounts
When two billing accounts for the same group combine into one, measure at the group level. At the account level, the absorbed account looks like churn and the surviving one like expansion. NRR comes out the same either way, but GRR drops, because expansion is excluded from GRR and so the fake churn is never offset.
Pellacombe Rota · 12 months to 31 October 2026
Net and gross revenue retention
NRR 97.3%, GRR 86.6%.
The customers you started with now pay you less.
Your cohort’s MRR movements (£ a month)
Customers live on day one only
Upgrades, seats, add-ons, price rises
Downgrades by customers who stayed
Starting MRR of customers who left
Results
- Ending MRR, same customersStart + expansion − contraction − churn
- £9,047
- Net revenue retentionEnding ÷ starting
- 97.3%
- Gross revenue retention(Start − contraction − churn) ÷ start
- 86.6%
- Expansion needed for 100% NRRContraction + churn
- £1,250
Retention bridge
Green: starting and ending MRR, and expansion. Gold: contraction and churn. New customers never appear in this bridge.
Edge cases on the example cohort
Tick a common mistake to see what it does to the same 15 accounts. All unticked is the correct treatment.
NRR
97.3% no change
GRR
86.6% no change
| Account | Customer | Billing | Start £ | End £ | Treated as |
|---|---|---|---|---|---|
| ACC-1108P01 | Dental group, 9 sitesAdded 3 sites on 14 Jun; the £255 proration invoice for the rest of June is a one-off, not MRR | Monthly | 1,200 | 1,650 | Expansion |
| ACC-1139P02 | Care home groupPrepaid £14,400 a year; renewed in March at £16,800 (÷ 12) | Annual prepay | 1,200 | 1,400 | Expansion |
| ACC-1254P03 | Veterinary practiceNo change | Monthly | 450 | 450 | Flat |
| ACC-1279P04 | Physiotherapy chainDropped the payroll export add-on in July | Monthly | 900 | 600 | Contraction |
| ACC-1293P05 | Nursery groupCancelled in May | Monthly | 650 | 0 | Churn |
| ACC-1366P06 | OpticiansCancelled in February, came back in August on a larger plan | Monthly | 380 | 420 | Expansion |
| ACC-1370P07 | Pharmacy group, IrelandBilled in euros; price unchanged | MonthlyEUR 1,500 → 1,500 | 1,305 | 1,305 | Flat |
| ACC-1410P08 | Clinic group (main company)Absorbed its sister company’s account in September | Monthly | 400 | 650 | Contraction |
| ACC-1430P08 | Clinic group (sister company)Closed when merged into the main account | Monthly | 300 | 0 | Contraction |
| ACC-1531P09 | Home care agency, USBilled in dollars; added a second region in April | MonthlyUSD 2,000 → 2,400 | 1,560 | 1,872 | Expansion |
| ACC-1560P10 | Single-site practiceCancelled in March | Monthly | 250 | 0 | Churn |
| ACC-1639P11 | Recruitment agencyGave notice in October; term runs to January 2027, so still live at period end | Annual prepay | 700 | 700 | Flat |
| ACC-1830P12 | HospiceNew customer in February | Monthly | 0 | 800 | Excluded: not live at start |
| ACC-1852P13 | Dental practiceNew customer in July | Monthly | 0 | 500 | Excluded: not live at start |
| ACC-1879P14 | Physiotherapy practiceLeft in August 2025, before the period; returned in April | Monthly | 0 | 300 | Excluded: not live at start |
Worked example (illustrative, fictional)
Pellacombe Rota, a fictional scheduling software vendor, measures retention for the 12 months to 31 October 2026. Rates on the start date are €1 = £0.87 and $1 = £0.78; on the end date they are £0.845 and £0.74. All rates and accounts are invented.
| Group | Customer | Start £ | End £ | Class | Movement £ |
|---|---|---|---|---|---|
| P01 | Dental group, added 3 sites in June | 1,200 | 1,650 | Expansion | +450 |
| P02 | Care home group, annual £14,400 renewed at £16,800 | 1,200 | 1,400 | Expansion | +200 |
| P03 | Veterinary practice | 450 | 450 | Flat | 0 |
| P04 | Physiotherapy chain, dropped an add-on | 900 | 600 | Contraction | −300 |
| P05 | Nursery group, cancelled | 650 | 0 | Churn | −650 |
| P06 | Opticians, left February, back in August | 380 | 420 | Expansion | +40 |
| P07 | Pharmacy group, €1,500 unchanged | 1,305 | 1,305 | Flat | 0 |
| P08 | Clinic group, two accounts merged (400 + 300 → 650) | 700 | 650 | Contraction | −50 |
| P09 | Home care agency, $2,000 → $2,400 | 1,560 | 1,872 | Expansion | +312 |
| P10 | Single-site practice, cancelled | 250 | 0 | Churn | −250 |
| P11 | Recruitment agency, notice given, term to January | 700 | 700 | Flat | 0 |
| Cohort total | 9,295 | 9,047 | −248 |
Three further customers joined during the year (£800, £500 and £300 at the end, £1,600 in total, one of them a returning former customer who left before the period). They are excluded.
Step by step:
- Expansion: 450 + 200 + 40 + 312 = £1,002
- Contraction: 300 + 50 = £350
- Churn: 650 + 250 = £900
- Ending MRR: 9,295 + 1,002 − 350 − 900 = £9,047
- NRR: 9,047 ÷ 9,295 = 97.3%
- GRR: (9,295 − 350 − 900) ÷ 9,295 = 8,045 ÷ 9,295 = 86.6%
The P01 upgrade generated a proration invoice of £255 for the rest of June (£450 × 17 ÷ 30). It appears nowhere above. Now the same cohort with each common mistake made on its own:
| Mistake | NRR | GRR | What happened |
|---|---|---|---|
| Correct treatment | 97.3% | 86.6% | |
| Include the three joiners | 114.5% | 86.6% | £1,600 of new MRR added to the top line: 10,647 ÷ 9,295 |
| Count P06 as churned | 92.8% | 82.5% | £380 moves to churn and its £40 expansion disappears |
| Convert at end-date rates | 95.9% | 86.1% | P07 shows £37.50 contraction; P09's expansion shrinks from £312 to £216 |
| Measure billing accounts, not groups | 97.3% | 83.9% | P08 becomes £300 churn plus £250 expansion |
The first row is the one to watch. A business shrinking within its existing base reports above 100% because new sales were counted. GRR is unaffected by that mistake, which is a good reason to always publish the two side by side.
Where your figure will differ from the billing system's
Stripe's revenue retention by cohort groups subscribers by when they first started generating positive MRR, and its documentation notes that cohort revenue can exceed 100% because it includes upgrades. That is a fine view of acquisition cohorts, but it is not the same as one company-wide NRR over a fixed window. Stripe also states that filtering and grouping some charts by product or price is unavailable if you process subscription volume in more than one currency.
Chargebee's retention documentation gives NRR as total end MRR over total beginning MRR for subscriptions active in the previous period. Its definitions are written at subscription level, so check how merged or multi-subscription customers are grouped before comparing its number with yours.
Neither is wrong. They answer slightly different questions, and the board pack should say which definition it uses.
Automating it with IVP.ai
The IVP.ai Data Layer reads subscriptions, prices and customers from your billing system each night, holds your customer-group mapping and start-date exchange rates as governed tables, and stores a dated MRR snapshot for every group. Because the snapshots are kept, any period's NRR and GRR can be recalculated from the same rules later, and the edge-case classification for each customer is visible rather than buried in a spreadsheet formula. The Stripe integration page covers that connection.
A Deskless by IVP.ai agent can then check each month's movements before they reach the pack: it flags billing accounts with no group mapping, reactivations, currency swings and customers on notice for a person to confirm. By default it flags and waits; it does not change billing records. More on Deskless.
Retention feeds directly into the SaaS board pack, and the SaaS cohort retention template shows the same customers by start month. Other templates are on the SaaS reporting hub. For context on build cost, one fintech saved over £120,000 compared with building the same data platform in-house (case study).
To see your own NRR and GRR calculated this way, start with the free 48-hour build. We connect up to three sources, typically billing, CRM and accounts, clean the data and set one report or agent running on real data within 48 hours of read-only access. You then have 14 days of access to choose a plan or walk away.