How to Group Data by Month in Excel

This guide will explain how to group data by month in Excel using two easy methods.

Excel is an excellent tool for storing, organizing, and manipulating data. Since it has several built-in tools and functions, we can easily perform difficult and time-consuming tasks such as arranging data by specific conditions.

Specifically, we can group data by month in Excel with the help of the pivot table. Additionally, we can perform the same task without using the pivot table. Instead, we will use functions to group data by month.

Furthermore, the ability to group data by month makes it easier to perform calculations or interpret our data set. Since the data is arranged, we can draw accurate conclusions or interpretations. 

Let’s take a sample scenario wherein we must group data by month in Excel.

Suppose we are creating a sales report containing the date of sales and the number of sales made. And you are tasked to group the number of sales by month to make it easier to interpret the report. 

Luckily, you can easily do this by using the pivot table. So the pivot table automatically groups the data by month. 

Great! Now we can move on and dive into a real example of grouping data by month in Excel.

 

A Real Example of Grouping Data by Month in Excel

Let’s say we have a data set containing two columns. So the first column has the sales date while the second column has the number of sales made during that specific date. So our initial data set would look like this:

Initial data set

 

We want to group the number of sales by month based on the sales date. To do this, we can use two simple and easy methods. Firstly, we can utilize the pivot table to automatically arrange the data by month. However, you can also choose to manually group the data by month using the pivot table.

Essentially, the pivot table is a powerful tool in Excel that allows us to summarize, calculate, and analyze data which helps us see patterns or trends in our data set.

When we convert our data set to a pivot table, it usually automatically groups and arranges the data by month. Furthermore, the pivot table is easy to use since we simply need to choose the fields we want to display or add to the table. Then, it automatically groups the data and displays the results.

However, we can also group data by month manually using the pivot table. To do this, we would need to first turn off the option that automatically groups data by date or time in pivot tables. Then, we can follow the same steps as the previous methods. 

Firstly, we will select our data set and convert them into a pivot table. Next, we will select the fields we want to add or display in the pivot table. Additionally, we will select any date in the pivot table and use the group selection option. Afterward, we can choose the grouping options, which is Months. 

Lastly, we can also use the built-in functions in Excel to group data by month in cases where the pivot table may not be available to use. And we will be utilizing the MONTH, YEAR, and SUMIF functions. 

Basically, we will use a formula with the combination of the MONTH and YEAR functions to obtain a numeric value of the month based on the date of sales. Then, we will use the SUMIF function to get the sum of sales by month. Finally, our final data set would look like this:

Final output

 

You can make your own copy of the spreadsheet above using the link attached below. 

Amazing! Now we can discuss the steps of how to group data by month in Excel.

 

How to Group Data by Month in Excel

In this section, we will discuss the step-by-step process of how to group data by month in Excel. Furthermore, we will explore two methods of doing this specific task. 

Since each step has detailed instructions and pictures to help you along the way, simply follow the steps to apply them to your work. 

1. Firstly, we need to convert the data set into a pivot table. To do this, we must select the entire data set and go to the Insert tab. Then, we will select PivotTable. Next, we will click From Table/Range in the dropdown menu.

Conver to pivot table

 

2. Secondly, we will choose the Existing Worksheet option in the PivotTable from table or range window. Then, we will select a cell location to input our pivot table. Lastly, we will click OK to apply the changes.

Dsiplay pivot table

 

3. Thirdly, we must select the fields we want to add or display to the pivot table. On the right side, the PivotTable Fields menu will open. So we will simply check the Date and Number of Sales to display them in the pivot table.

Add pivot table fields

 

4. And tada! The pivot table automatically groups the data by month.

Group Data by Month in Excel

 

5. However, we can also perform this manually. To do this, we first need to turn off the option that automatically groups dates. So we will select File at the top left and select More at the very bottom of the page. Then, we will click Options.

Group Data by Month in Excel

 

6. Next, we will go to Data and check Disable automatic grouping of Date/Time columns in PivotTables. Lastly, we will click OK to apply the changes.

Group Data by Month in Excel

 

7. Then, we will follow the same steps as before. So select the entire data set and go to the Insert tab. Next, we will click PivotTable and From Table/Range.

Group Data by Month in Excel

 

8. Afterward, we will select the Existing Worksheet option and input a cell location to display the pivot table. Lastly, click OK.

Group Data by Month in Excel

 

9. Next, we will select the same fields to add to our pivot table.

Group Data by Month in Excel

 

10. Then, we will select any date in our pivot table and go to the PivotTable Analyze tab. After, we will select Group and click Group Selection in the dropdown menu.

Group Data by Month in Excel

 

11. In the Grouping window, we will choose Months under the By options. Lastly, we will click OK to apply the changes.

Group Data by Month in Excel

 

12. And tada! We have manually grouped data by month using the pivot table.

Group Data by Month in Excel

 

13. Additionally, we can also utilize a formula to group data by month. Firstly, we will create a new column to display the Serial of Months. So we will type in the formula “=MONTH(B2)+((YEAR(B2)-2022)*12)”. Lastly, we will press the Enter key to return the result.

Group Data by Month in Excel

 

14. Next, we will drag down the Fill Handle tool to apply the formula to the rest of the cells.

Group Data by Month in Excel

 

15. Then, we will create another column to display the Sum of Sales by Month. So we will input the formula “=SUMIF($E$2:$E$10,E2,$C$2:$C$10)”. Lastly, we will click the Enter key to return the result.

Group Data by Month in Excel

 

16. Finally, we will drag the Fill Handle tool down to copy and apply the formula.

Group Data by Month in Excel

 

17. And tada! We have successfully grouped data by month using a formula in Excel.

Group Data by Month in Excel

 

And that’s pretty much it! We have explained how to group data by month in Excel. Furthermore, we discussed how to use the pivot table and the built-in function in Excel to perform this task. Now you can choose any method that works best for you and apply them to your work. 

Are you interested in learning more about what Excel can do? You can now use the YEAR function and the various other Microsoft Excel formulas available to create great worksheets that work for you. Make sure to subscribe to our newsletter to be the first to know about the latest guides and tutorials from us.

Get emails from us about Google Sheets.

Our goal this year is to create lots of rich, bite-sized tutorials for Google Sheets users like you. If you liked this one, you'll love what we are working on! Readers receive ✨ early access ✨ to new content.

0 Shares:
Leave a Reply

Your email address will not be published. Required fields are marked *

You May Also Like