Smart Systems for Home

Plain how-to guides for smart home, security and home Wi-Fi

Excel PivotTable Group Dates by Early, Middle, Late Month

· 6 min read · Home Tech

In this article
  1. Why Group Dates into Thirds of a Month
  2. Step-by-Step: Add a Helper Column
  3. The Formula: How to Write It
  4. Using a Calculated Field vs. Helper Column
  5. Common Mistakes and How to Avoid Them
  6. Alternatives: Grouping by Week or Custom Dates
  7. Frequently Asked Questions

Excel PivotTables can group dates into early, middle, and late month segments by adding a helper column that assigns each day to a third of the month, then grouping by that column in the PivotTable. You enter your date column, create a calculated field or helper column with a formula, and then drag that field into the Row Labels area to see counts or sums for each third. This article explains the exact steps, the formula logic, common pitfalls, and how to adjust the boundaries to fit your reporting needs.

Why Group Dates into Thirds of a Month

Standard PivotTable date grouping lets you group by day, month, quarter, or year. But sometimes you need a coarser view than daily and a finer view than monthly—for example, “early month” (days 1–10), “middle month” (days 11–20), and “late month” (day 21 to month end). This is common in sales reporting, payroll cycles, inventory reviews, or any business that tracks performance in three distinct periods within a month.

Excel does not have a built-in “third of month” grouping. The workaround is to add a helper column to your source data that labels each date as “Early”, “Middle”, or “Late” based on the day of the month. Then you refresh the PivotTable and drag that helper field into the Rows area. The PivotTable will group all rows with the same label together, effectively creating three buckets per month.

Step-by-Step: Add a Helper Column

Before you build the PivotTable, you need a column that contains the third-of-month label. Here is the process:

  1. Open your data in Excel. Ensure each row has a date in a column (e.g., column A) and a value you want to summarize (e.g., sales amount in column B).
  2. Insert a new column to the right of your data (e.g., column C). Give it a header like “Month Third”.
  3. In cell C2 (assuming row 1 is headers), enter a formula that returns “Early”, “Middle”, or “Late” based on the day of the date in A2.
  4. Copy the formula down for all data rows.
  5. Create a PivotTable from the entire data range (including the new column).
  6. Drag the “Month Third” field into the Rows area, and drag your value field (e.g., Sales) into the Values area.
  7. Refresh the PivotTable if you change the helper column formulas.

The Formula: How to Write It

The simplest approach uses the DAY function to get the day number, then compares it to thresholds. A common formula is:

=IF(DAY(A2)<=10,"Early",IF(DAY(A2)<=20,"Middle","Late"))

This assigns days 1–10 to “Early”, 11–20 to “Middle”, and 21 to the last day of the month to “Late”. You can adjust the numbers 10 and 20 to change the boundaries—for example, using 7 and 21 for weeks, or 15 and 25 for a different split.

If you want the labels to appear in a specific order (Early, Middle, Late) in the PivotTable, you can either sort them manually or use a custom list. Without a custom list, Excel will sort alphabetically: Early, Late, Middle. To fix that, you can add a numeric sort column (e.g., 1, 2, 3) and use it as a secondary row field, or use the PivotTable’s sort options.

Using a Calculated Field vs. Helper Column

Some users try to create a calculated field inside the PivotTable itself. However, calculated fields in PivotTables cannot reference the DAY function directly on a date field because they work on aggregated values, not row-level data. The only reliable way is to add a helper column to the source data. If you are using Excel Tables (Insert > Table), the formula will automatically fill down when you add new rows, which is convenient.

If your data is in Power Pivot or a Data Model, you can create a calculated column using DAX with a similar IF logic. But for a standard PivotTable from a worksheet range, the helper column is the standard method.

Common Mistakes and How to Avoid Them

  • Not refreshing after adding the helper column: If you add the column after creating the PivotTable, you must refresh (Data > Refresh) and also ensure the source range includes the new column. If your source is a named range, update it.
  • Using the date field instead of the helper field: If you drag the actual date into Rows, you will still get daily grouping. You must drag the “Month Third” field, not the date.
  • Boundary confusion: The formula uses <=10 and <=20. If you use <10, day 10 becomes “Middle”, which may not be what you intend. Double-check your thresholds.
  • Sorting order: As mentioned, alphabetical sorting puts “Late” before “Middle”. To force Early, Middle, Late, you can create a custom list (File > Options > Advanced > Edit Custom Lists) or add a numeric prefix like “1-Early”, “2-Middle”, “3-Late”.

Alternatives: Grouping by Week or Custom Dates

If your “early, middle, late” actually means weeks, you can use Excel’s built-in grouping by days and set the number of days to 7. But that groups by week number, not by calendar thirds. For a true third-of-month split, the helper column is the only direct way.

Another alternative is to group by month and then use a slicer or filter to view one month at a time, but that does not give you the three sub-periods in a single view. If you need to compare early vs. late across multiple months, the helper column approach is best because it keeps the month context in a separate field—you can group by month and by “Month Third” simultaneously.

Frequently Asked Questions

Can I group by early, middle, late without a helper column?

No. PivotTables do not have a built-in option for thirds of a month. The helper column is the standard workaround. You could use a GETPIVOTDATA formula or a separate summary table, but that is more complex and less flexible.

What if my month has 31 days? Does the formula handle it?

Yes. The formula checks if the day is less than or equal to 10, then less than or equal to 20, otherwise “Late”. For a 31-day month, days 21–31 are all “Late”. For February, days 21–28 (or 29) are “Late”. The formula does not need to know the month length.

How do I change the boundaries to 1–7, 8–14, etc.?

Simply edit the numbers in the IF formula. For example, =IF(DAY(A2)<=7,"Early",IF(DAY(A2)<=14,"Middle","Late")) gives you three approximately equal weeks. You can use any thresholds you like.

Why does my PivotTable show “(blank)” for the Month Third field?

This usually means some rows in the helper column are blank. Check that the formula was copied down for all data rows, and that there are no blank cells in the date column. You can also filter out blanks in the PivotTable.

Can I use this with a PivotChart?

Yes. Once the PivotTable is built with the “Month Third” field, you can insert a PivotChart from it. The chart will show three categories per month if you also include the month field in Rows.

Does this work in Excel Online or Google Sheets?

Excel Online supports PivotTables and helper columns, so the same method works. Google Sheets also has PivotTables, and you would use a similar formula (e.g., =IF(DAY(A2)<=10,"Early",...)) in a helper column. The steps are essentially the same.