How to Convert Start and End Dates to Monthly Excel Columns
Question details
The user needs to expand a large dataset containing start and end dates into monthly columns without generating unnecessary values outside the applicable date ranges.

- Product
- Excel
- Device & OS
- not provided
- Scenario
- Expanding records across applicable months based on specific start and end dates for detailed monthly analysis.
- Observed behavior
- The goal state is a dynamically expanded table with monthly headers and values corresponding only to the active months for each individual record.
Ensure your dataset is formatted as an Excel Table and that your start and end date columns contain valid, recognizable date values rather than plain text.
Use Power Query to Unpivot and Expand Dates
Power Query is the most reliable and efficient method for expanding large datasets (over 200,000 records) into monthly columns without slowing down your workbook.
Power Query allows you to transform your data structurally. By creating a list of dates between your start and end points and expanding them, you can accurately map values to the correct months.
Select your data range, navigate to the Data tab, and click 'From Table/Range' to open the Power Query Editor.
Select your start and end date columns, right-click the headers, and choose 'Unpivot Other Columns' to flatten any existing monthly labels into rows.
Go to the Add Column tab, click 'Custom Column', and write a formula using List.Dates to generate a continuous list of months between your start and end dates.
Click the expand icon (two diverging arrows) on your new custom column header and select 'Expand to New Rows' to duplicate the record for each applicable month.
Once formatted, go to the Home tab and click 'Close & Load' to export the expanded, monthly-aligned table back into your Excel worksheet.

Use Microsoft 365 Dynamic Array Formulas
If you use Microsoft 365, you can use advanced dynamic array functions to generate the monthly headers and populate values directly in the spreadsheet grid.
Expand Data and Manage Dates with WPS Spreadsheet
WPS Spreadsheet offers powerful data processing tools, including dynamic array functions and advanced data transformation capabilities to help you manage date ranges efficiently.
- 1. Open your file in WPS Spreadsheet: Launch WPS Office and open your Excel workbook containing the start and end dates.
- 2. Apply dynamic array formulas: Use functions like SEQUENCE and EOMONTH directly in the grid to calculate the monthly span automatically.
- 3. Analyze and format: Use WPS Spreadsheet's conditional formatting and pivot tables to summarize and visualize your dynamically expanded monthly data.

Frequently Asked Questions
Why are my newly generated date columns showing as numbers instead of months?
Excel stores dates as sequential serial numbers. To fix this, select your newly generated monthly headers or columns, right-click, choose 'Format Cells', and apply a 'Date' or 'Custom' format (such as 'mmm-yyyy').
Can I expand date ranges to monthly columns without Microsoft 365?
Yes. If you are using an older version of Excel or a free alternative like WPS Office, you can use the Power Query method to unpivot and expand the dates without relying on newer dynamic array functions.
Why is my dynamic array formula returning a #SPILL! error?
A #SPILL! error occurs when the dynamic array formula doesn't have enough empty adjacent cells to display all the generated monthly columns and rows. Locate and clear any existing data or spaces blocking the spill range.




