Table of Contents
Calculating Quarters Between Dates: The Essential Excel Formula
Microsoft Excel is a powerful tool for complex time series analysis, but calculating the precise number of full quarters between two specific dates often requires a sophisticated approach. Unlike simple subtraction, this calculation must account for the varying lengths of months and ensure that only complete three-month periods are counted. We present the definitive formula that accurately determines the number of full quarters elapsed between a starting date and an ending date.
To determine the number of quarters between two dates, typically stored in cells, you can employ a method that first converts both dates into a total count of months since a standardized reference point (such as January 1, 1900), finds the difference, and then divides that difference by three. This calculation is encapsulated in the following robust formula:
=FLOOR(((YEAR(B2)*12+MONTH(B2))-(YEAR(A2)*12+MONTH(A2)))/3,1)
This specific mathematical expression is designed to calculate the total number of full quarters separating the starting date, located in cell A2, and the final or ending date, located in cell B2. The use of the FLOOR function ensures that only whole quarters are counted, effectively rounding down any partial quarter periods.
Setting Up the Data for Calculation
To demonstrate the practical application of this formula, consider a typical scenario where you have multiple pairs of start and end dates that require quarterly interval calculation. Effective date management is crucial in financial reporting and project management, making this formula highly valuable for analyzing temporal data sets.
Suppose we have organized our data into two columns within an Excel spreadsheet, identifying the start dates in Column A and the end dates in Column B, as illustrated below. Our goal is to populate Column C with the accurate number of quarters between each corresponding start and end date pair.

We will now proceed to apply the quarter calculation mechanism to the first row, specifically targeting cells A2 and B2, before extending the logic to the rest of the dataset.
Executing the Formula and Interpreting Results
To initiate the calculation process, we must enter the previously defined formula into the first vacant cell of our results column, which is cell C2. This single entry will serve as the template for calculating the interval for all subsequent date pairs.
Type the following formula precisely into cell C2:
=FLOOR(((YEAR(B2)*12+MONTH(B2))-(YEAR(A2)*12+MONTH(A2)))/3,1)
Once the formula is entered, press Enter. The calculated result for the first row will appear. To apply this sophisticated logic to the entire dataset, simply click and drag the fill handle (the small square at the bottom-right corner of cell C2) down to encompass all remaining rows in Column C. This action automatically adjusts the cell references (A2, B2, etc.) for each respective row, performing the necessary calculation across the board.

Upon completion of this step, Column C now accurately displays the determined number of complete quarters between every corresponding start date and end date. Analyzing the resulting data confirms the efficiency of the calculation:
- There are 8 full quarters between 1/1/2018 and 2/15/2020.
- There are 3 full quarters between 3/12/2019 and 2/19/2020.
- Note that there are 0 full quarters between 3/15/2019 and 4/16/2020, as this interval does not span three complete, consecutive three-month periods defined by the start date.
Deconstructing the Logic: Understanding the Formula Components
To fully appreciate the accuracy of the result, it is beneficial to understand the underlying mechanics of the formula. Let us revisit the core expression used to calculate the interval between the start date in A2 and the end date in B2:
=FLOOR(((YEAR(B2)*12+MONTH(B2))-(YEAR(A2)*12+MONTH(A2)))/3,1)
This formula operates by translating the dates into a common numerical scale, allowing for precise subtraction. The process can be broken down into three distinct, sequential steps that leverage Excel’s date system:
Converting the End Date to Total Months: The first operation,
YEAR(B2)*12+MONTH(B2), calculates the total number of months that have elapsed between Excel’s baseline date (January 1, 1900) and the specific date in cell B2. For example, if B2 contains 2/15/2020, this calculation might return a value like 24242, representing the total months passed, factoring in the results of the YEAR function and the MONTH function.Converting the Start Date to Total Months: Similarly, the expression
YEAR(A2)*12+MONTH(A2)computes the total number of months elapsed from the baseline date up to the start date in cell A2. If A2 contains 1/1/2018, this component would return a value such as 24217.Calculating Quarters and Rounding: We then subtract the two values (24,242 – 24,217 = 25). This result (25) represents the exact number of months between the two dates. This monthly difference is then divided by 3 (since there are three months in a quarter), yielding 25 / 3 = 8.333. Finally, the external FLOOR function is applied to round this number down to the nearest integer specified by the argument
1, resulting in 8. This final integer represents the number of full, complete quarters that fit entirely within the defined time span.
This methodical approach ensures that the calculation is based on the difference in months, regardless of the complexity of the dates or the years they span. The formula is then automatically repeated for every subsequent row in the dataset, providing consistent and accurate quarterly interval analysis.
Further Resources for Advanced Excel Operations
Mastering date and time calculations in Excel is fundamental for various analytical tasks. If you are looking to expand your proficiency beyond quarterly calculations, the following tutorials explain how to perform other common and complex operations related to time series and financial modeling in Excel.
Cite this article
Mohammed looti (2025). Learn to Calculate Quarters Between Dates in Excel: A Step-by-Step Guide. PSYCHOLOGICAL STATISTICS. Retrieved from https://statistics.arabpsychology.com/excel-calculate-number-of-quarters-between-two-dates/
Mohammed looti. "Learn to Calculate Quarters Between Dates in Excel: A Step-by-Step Guide." PSYCHOLOGICAL STATISTICS, 10 Nov. 2025, https://statistics.arabpsychology.com/excel-calculate-number-of-quarters-between-two-dates/.
Mohammed looti. "Learn to Calculate Quarters Between Dates in Excel: A Step-by-Step Guide." PSYCHOLOGICAL STATISTICS, 2025. https://statistics.arabpsychology.com/excel-calculate-number-of-quarters-between-two-dates/.
Mohammed looti (2025) 'Learn to Calculate Quarters Between Dates in Excel: A Step-by-Step Guide', PSYCHOLOGICAL STATISTICS. Available at: https://statistics.arabpsychology.com/excel-calculate-number-of-quarters-between-two-dates/.
[1] Mohammed looti, "Learn to Calculate Quarters Between Dates in Excel: A Step-by-Step Guide," PSYCHOLOGICAL STATISTICS, vol. X, no. Y, ص Z-Z, November, 2025.
Mohammed looti. Learn to Calculate Quarters Between Dates in Excel: A Step-by-Step Guide. PSYCHOLOGICAL STATISTICS. 2025;vol(issue):pages.