A rolling 12-month total (trailing twelve months, TTM) smooths out seasonality by always summing the last twelve months. As each new month arrives, the window slides forward automatically.
The example
Each month sums itself plus the prior 11.
| A | B | C | |
|---|---|---|---|
| 1 | Month | Sales | TTM |
| 2 | Dec Y1 | $8,000 | $92,000 |
| 3 | Jan Y2 | $7,500 | $94,500 |
The formula
Sum the trailing twelve months:
How it works
A sliding 12-row window does the work:
OFFSET(currentCell, 0, 0, -12, 1)defines a 12-row tall block ending at the current month (negative height counts upward).SUMtotals that block — the trailing twelve months.- Copy down; each row’s window slides forward by one month automatically.
- Only valid once you have 12 months of history; earlier rows would sum fewer than 12.
Prefer a sturdier formula? If your data has a date column, =SUMIFS(values, dates, ">"&EDATE(thisMonth,-12), dates, "<="&thisMonth) avoids OFFSET’s volatility and survives inserted rows.
Try it: interactive demo
Enter monthly values (one per line); TTM = last 12.
Variations
SUMIFS by date (robust)
Date-driven window:
Rolling 3-month
Change the height:
Rolling average
Divide by the window:
Pitfalls & errors
Needs 12 months first. Rows before the 12th sum a short window — blank them or wait until enough history exists.
OFFSET is volatile. It recalculates often and can be fragile with inserted rows; the SUMIFS-by-date form is sturdier for big models.
Gaps break the count. OFFSET counts rows, not months — missing months throw the window off. Keep one row per month.
Practice workbook
Frequently asked questions
How do I calculate a rolling 12-month total in Excel?
Why is OFFSET risky for rolling totals?
How do I make a rolling 3-month total instead?
Stop fighting formulas. Learn them in a day.
This recipe is one of hundreds of real-world formulas we teach. Our Excel Formulas & Functions class covers lookups, logic, text, and dynamic arrays hands-on — live in Dallas–Fort Worth, Houston, Austin, Oklahoma City, Denver, or online.
See the Formulas & Functions Class