docs / articles / Excel: Calculate Days Difference in Calendar

Excel: Calculate Days Difference in Calendar

Eric Jul 09, 2026 2026-07-09 04:40:47

Calculating the difference in calendar days in Excel is a common task when working with dates. Whether you're tracking project timelines, determining age, or calculating delivery dates, Excel provides several methods to achieve this. Let's explore two efficient ways to calculate calendar day differences in Excel.

Calculate Number of Days Between Two Dates in Excel - TheAppTimes
Calculate Number of Days Between Two Dates in Excel - TheAppTimes

Before we dive into the methods, ensure your dates are formatted correctly. Select the cells containing dates, right-click, and choose 'Format Cells'. Under 'Number', select 'Date' and choose your preferred date format.

Calculate Number of Days Between Two Dates in Excel (8 Quick Tricks)
Calculate Number of Days Between Two Dates in Excel (8 Quick Tricks)

Using the DATEDIF Function

The DATEDIF function in Excel calculates the difference between two dates based on a specified unit. It's a powerful tool for calculating age, time between two dates, and more.

an image of a calendar in microsoft office 365 with the date and time tab open
an image of a calendar in microsoft office 365 with the date and time tab open

Syntax: DATEDIF(start_date, end_date, unit)

Calculating Age

Get Difference between Two Dates in Year, Month and Days in Excel | Find difference between two date
Get Difference between Two Dates in Year, Month and Days in Excel | Find difference between two date

The 'DATEDIF' function can calculate age by using the 'Y' unit, which represents years. For example, to calculate the age of someone born on January 1, 1990, use the following formula:

DATEDIF(A1, TODAY(), "Y")

Replace 'A1' with the cell containing the birthdate. The 'TODAY()' function returns the current date. The result will be the age in years.

Calender in Excel ‼️ Amazing Excel trick using data validation and conditional formatting ✅ #Excel
Calender in Excel ‼️ Amazing Excel trick using data validation and conditional formatting ✅ #Excel

Calculating Days Between Two Dates

To find the number of days between two dates, use the 'D' unit. For instance, to find the number of days between dates in cells A1 and B1, use the following formula:

DATEDIF(A1, B1, "D")

How to Make a Calendar in Excel [Complete Guide + Free Templates] - GeeksforGeeks
How to Make a Calendar in Excel [Complete Guide + Free Templates] - GeeksforGeeks

If the start date is later than the end date, the result will be negative. To always get a positive result, wrap the formula in the ABS function:

ABS(DATEDIF(A1, B1, "D"))

Excel DATEDIF function to get difference between two dates
Excel DATEDIF function to get difference between two dates
Get Difference between Two Dates in Excel | Calculate difference between Two Dates in Excel | Excel
Get Difference between Two Dates in Excel | Calculate difference between Two Dates in Excel | Excel
Excel Autofill - how to quickly enter Months, Days, Dates and Numbers without typing
Excel Autofill - how to quickly enter Months, Days, Dates and Numbers without typing
Calculate Working Days between two Dates in Excel: Find Workdays Excluding Holidays & Weekends
Calculate Working Days between two Dates in Excel: Find Workdays Excluding Holidays & Weekends
Free Excel Calendar Template
Free Excel Calendar Template
Excel Formula to Calculate Number of Days Between Two Dates - ExcelDemy
Excel Formula to Calculate Number of Days Between Two Dates - ExcelDemy
Don't save the date 📆
Don't save the date 📆
How to make a dynamic calendar in excel
How to make a dynamic calendar in excel
Calculate the difference between two times in Excel - PakAccountants.com
Calculate the difference between two times in Excel - PakAccountants.com
How to insert dates from a Popup Calendar (date picker) in Excel – user guide | XLTools
How to insert dates from a Popup Calendar (date picker) in Excel – user guide | XLTools
Calendar in Excel: Make Dynamic, Interactive Calendar in Excel with Formula + Conditional Formatting
Calendar in Excel: Make Dynamic, Interactive Calendar in Excel with Formula + Conditional Formatting
How to Make an Interactive Calendar in Excel? (2026 Template)
How to Make an Interactive Calendar in Excel? (2026 Template)
How to Insert a Calendar in Excel (the Simplest Way)
How to Insert a Calendar in Excel (the Simplest Way)
Calculate Difference between Two Dates in Excel: Get Number of Years Months Days with Excel Formula
Calculate Difference between Two Dates in Excel: Get Number of Years Months Days with Excel Formula
Create a Calendar in Excel - Tutorial
Create a Calendar in Excel - Tutorial
Ready to kick off 2025 with organisation and style?
Ready to kick off 2025 with organisation and style?
How to Make & Format a Calendar in Excel - Tutorials
How to Make & Format a Calendar in Excel - Tutorials
How to Create a Timestamp in Excel
How to Create a Timestamp in Excel
How to put dates in excel!
How to put dates in excel!
a calendar with the date and time for january to march 2013, including dates on each page
a calendar with the date and time for january to march 2013, including dates on each page

Using the NETWORKDAYS Function

The NETWORKDAYS function calculates the number of whole workdays between two dates. It's useful for calculating business days, excluding weekends and holidays.

Syntax: NETWORKDAYS(start_date, end_date, [holidays])

Calculating Business Days

To calculate the number of business days between two dates, use the following formula:

NETWORKDAYS(A1, B1)

Replace 'A1' and 'B1' with the cells containing the start and end dates, respectively.

Including Holidays

If you need to exclude specific holidays, list them in a range of cells and include it in the formula:

NETWORKDAYS(A1, B1, holidays_range)

Replace 'holidays_range' with the range containing the holiday dates. For example, if holidays are listed in cells A2:A5, use 'A2:A5' as the range.

Remember to format the result as a number for easier reading. Right-click the cell containing the result, choose 'Format Cells', under 'Number', select 'Number' and choose the desired number of decimal places.

In the world of data analysis, accurately calculating calendar day differences is crucial. Excel's DATEDIF and NETWORKDAYS functions provide powerful tools to achieve this. By mastering these functions, you'll streamline your workflow and gain insights more efficiently. Happy calculating!