Average monthly sales with AVERAGEX and VALUES
Work out a typical month’s sales for any product, region or year by averaging monthly totals with AVERAGEX.
You will learn to
- Average a measure over a list of months
- Explain why AVERAGEX skips months with no sales
- Avoid hard-coding the number of months
How it works
“What does a typical month look like?” is one of the most common questions in a sales report. The answer is an average of **monthly totals**, not an average of order lines.
To get monthly totals you need one row per month. `VALUES('Date'[Month Year])` gives you the months visible in the current cell: all 24 in a card, only 2025’s twelve when a slicer picks 2025.
`AVERAGEX` evaluates a measure for each of those rows, with context transition filtering it to that month, and averages the results. Months where the measure is blank are skipped, so the average describes the months that actually had sales.
Dividing by a fixed number such as 12 looks simpler, but it is only right when exactly twelve months are visible and every one of them had sales.
Practice it hands-on with a real data model and a live report that updates as you type.
Avg Quarterly Sales = AVERAGEX(VALUES('Date'[Quarter]), [Total Sales])