Sub topic 10
Rolling Monthly Figures Up to Annual Totals
What you will build and what you need
This chapter turns a monthly calculation block into an annual summary. It assumes you already have the monthly timeline from the earlier chapters. That means a single start-date input in C2, a fiscal year-end month number in C3, period ends in row 6, and fiscal year-end dates in row 9. You should also be comfortable with SUMIFS and with mixed references such as D$14.
The method has three parts:
- Build an annual header row of fiscal year-end dates.
- Match each monthly column to its annual column through the fiscal year-end date in row 9.
- Sum the monthly values with
SUMIFS, then prove the result with checks.
Why match on a date key
The monthly row already knows which fiscal year each month belongs to. Row 9 holds the fiscal year-end date for every month, so every month in the same fiscal year carries the same date. That date works as a key. An annual column asks for the sum of every monthly value whose key equals its own header date.
This approach has three advantages over summing fixed blocks of 12 columns:
- It works when the first fiscal year is partial. A model that starts in January with a June year-end has only six months in the first fiscal year.
- It works for any fiscal year-end month. Only
C3changes. - It needs no hand-edited ranges. If the start date moves, the keys move with it.
The annual header row
The first annual column finds the first fiscal year-end on or after the start date. Each later column steps forward 12 months.
Inputs: C2 = 15-Jan-2025 (model start date)
C3 = 6 (fiscal year-end month, June)
Annual header (row 14):
D14: =EOMONTH(C2,MOD($C$3-MONTH(C2),12))
E14: =EOMONTH(D14,12)MOD($C$3-MONTH(C2),12) is the number of months from the start month to the next fiscal year-end month. For January and a June year-end, that is MOD(6-1,12), which is 5. EOMONTH(15-Jan-2025,5) returns 30-Jun-2025. If the start month is already the year-end month, MOD returns 0 and the first annual column is the start month itself.
MOD is what makes this work when the year-end month number is smaller than the start month. With a start in October and a March year-end, 3-10 is -7. MOD(-7,12) returns 5, because Excel's MOD returns a result with the sign of the divisor. A plain subtraction would have given a negative step.
Each later column adds 12 months with EOMONTH. This is safe because month-end dates never clamp, so the sequence cannot drift. Format row 14 as dates. Without a date format you will see serial numbers such as 45838 and might think the row is broken.
The roll-up formula
Row 20 holds monthly revenue. Row 9 holds each month's fiscal year-end date. The annual revenue formula is:
Annual revenue (row 15):
D15: =SUMIFS($D$20:$AM$20,$D$9:$AM$9,D$14)
Row 20 holds monthly revenue; row 9 holds each month's fiscal year-end date.The anchoring matters for copying to the right:
$D$20:$AM$20is the sum range. It is fully absolute, so every annual column sums from the same monthly row.$D$9:$AM$9is the criteria range. It is also fully absolute and must have the same shape and size as the sum range. If the two differ,SUMIFSreturns#VALUE!.D$14is the criterion. The row is locked and the column is relative, so each annual column uses its own header date.
To roll up another line, such as costs in row 21, copy the formula down. The sum range needs a row-relative reference to follow. Write it as $D21:$AM21, with the column anchored and the row relative. The criteria range and D$14 stay locked.
Worked example
Assume 100 of revenue every month. The timeline starts on 15-Jan-2025 and has 36 monthly columns (D to AM), which run to December 2027. The fiscal year ends in June.
| Annual column | Header date (row 14) | Months matched | Revenue |
|---|---|---|---|
| D | 30-Jun-2025 | Jan to Jun 2025 (6) | 600 |
| E | 30-Jun-2026 | Jul 2025 to Jun 2026 (12) | 1,200 |
| F | 30-Jun-2027 | Jul 2026 to Jun 2027 (12) | 1,200 |
| G | 30-Jun-2028 | Jul to Dec 2027 (6) | 600 |
| H | 30-Jun-2029 | none | 0 |
The first and last fiscal years are partial because the timeline cuts them off. That is correct, not an error. Column H is spare capacity. It returns 0 because no monthly key matches it, which is useful if you later extend the monthly timeline.
Here is how one month finds its key. For July 2025, the period end in D6 is 31-Jul-2025. Row 9 computes EOMONTH(D6,MOD($C$3-MONTH(D6),12)). That is MOD(6-7,12), which is 11, and EOMONTH(31-Jul-2025,11) is 30-Jun-2026. This matches the header in E14, so July 2025 lands in the fiscal year labelled 2026.
A year-number variant
You can match on the fiscal year number instead of the full date. Row 10 already holds YEAR of the fiscal year-end date. Add a label row above the annual header and match on that.
Annual fiscal year label (row 13): D13: =YEAR(D14)
Annual revenue by year number: D15: =SUMIFS($D$20:$AM$20,$D$10:$AM$10,D$13)Both versions give identical results. The date key is stricter, because it needs the exact month end. The year number is easier to read in a formula and in a report. Pick one and use it consistently across the whole model.
Flows and balances
SUMIFS over all months in the year is right for flows, such as revenue, costs and cash movements. It is wrong for balances, such as cash, debt and receivables. A balance at the end of the year is the value in the last month, not the sum of twelve month-end balances.
For a balance, match on the period end instead of the fiscal year-end key. The annual header is a month-end date, so it equals exactly one period end in row 6.
Closing cash balance, monthly balances in row 30:
D31: =SUMIFS($D$30:$AM$30,$D$6:$AM$6,D$14)This finds the single month whose period end equals the annual header and returns its balance. SUMIFS works here because exactly one cell matches. A stub year at the end of the timeline, such as column G above, has no month ending on 30-Jun-2028. The formula returns 0 for it, which can be mistaken for a real zero balance. Decide how you want to display or flag that case.
| Item type | Examples | Annual rule | Match range |
|---|---|---|---|
| Flow | Revenue, costs, capex | Sum the months in the year | Row 9 (fiscal year-end key) |
| Balance | Cash, debt, inventory | Take the last month's value | Row 6 (period end) |
| Rate or ratio | Margin, growth | Recalculate from annual totals | Do not sum or average monthly rates |
Checks that catch silent errors
A roll-up can be wrong without showing an error. Three checks are worth building.
Annual tie-out (flows): =SUM(D20:AM20)-SUM(D15:H15) -> must be 0
Months per annual column: D16: =COUNTIFS($D$9:$AM$9,D$14)
Months tie-out: =SUM(D16:H16)-COLUMNS(D9:AM9) -> must be 0The first check compares the grand total of the monthly row with the grand total of the annual row. If the annual header misses a fiscal year, some months match nothing and the difference is non-zero. The second check counts the months matched by each annual column. Expect 12 for full years and fewer for partial years. The months tie-out confirms that every monthly column is claimed by exactly one annual column.
Common reasons for a failing check:
- The annual header is too short. The timeline covers more fiscal years than you have annual columns. Add columns or extend the header.
- The annual header is typed in, not calculated. A typed date can differ from the key, or be stored as text. Text never equals a number in
SUMIFS, so the column returns 0. - Ranges of different sizes. Extending the monthly timeline but not both ranges leaves one range shorter than the other.
- A time component in a date.
NOW()or a pasted timestamp adds a fraction to the serial number. UseEOMONTHfor all keys, because it always returns a whole day.
Key points
- Annual columns are keyed by fiscal year-end date. Monthly columns carry the same key in row 9.
- Build the annual header from
C2andC3, usingEOMONTHwithMODfor the first column andEOMONTH(previous,12)for the rest. - Use
SUMIFSfor flows. For balances, match the annual header against the period end. - Verify with a grand-total tie-out and a months-per-column count.
Exercise
A model starts on 10-Oct-2025 and has a fiscal year-end in March (C3 = 3). What formula gives the first annual header in D14, and what date does it return?
Show answer
D14: =EOMONTH(C2,MOD($C$3-MONTH(C2),12)). MONTH(C2) is 10, so MOD(3-10,12) = MOD(-7,12) = 5. EOMONTH(10-Oct-2025,5) returns 31-Mar-2026. The first fiscal year therefore covers 10-Oct-2025 to 31-Mar-2026, a partial year of six months.
Exercise
An annual revenue cell returns 0 although the monthly revenue row has values. The header cell D14 looks like a date, but it was pasted from a text file. Explain the cause, give a quick test, and give the fix.
Show answer
The pasted header is stored as text, and text never equals the numeric date keys in row 9, so SUMIFS matches no months. A quick test is =ISNUMBER(D14), which returns FALSE. It also helps to check whether the cell is left-aligned. The fix is to replace the header with the formula =EOMONTH(C2,MOD($C$3-MONTH(C2),12)) in the first column and =EOMONTH(D14,12) in the following columns. Then format the row as dates.
Exercise
The months-per-column row for a 36-month timeline starting 15-Jan-2025 with a June year-end shows 6, 12, 12, 6, 0. Is the timeline broken? What would the months tie-out return?
Show answer
No, the timeline is correct. The first and last fiscal years are partial, and the fifth annual column has no matching months. The counts add to 36, which equals COLUMNS(D9:AM9), so the months tie-out returns 0.