HomeGuides › How to Calculate Date Intervals
Date & Time

How to Calculate Date Intervals

Last updated: 2026-09-06

⚡ Quick Answer

The DATEDIF function calculates the exact elapsed time between two calendar dates in days, months, or years.

=DATEDIF(Start_Date, End_Date, "d")

📊 Visual Demo

Book1 - Excel
HOME · INSERT · FORMULAS · DATA
fx =DATEDIF(Start_Date, End_Date, "d")
ABCDE
112026-01-012026-03-01"d" (Days)59 Days
222024-06-282026-06-28"y" (Years)2 Years
33AuditTimeline CheckVerifiedAccurate Count

🧠 Deep Dive

The DATEDIF function calculates the exact elapsed time between two calendar dates in days, months, or years.

Key Insights

  • Excel dates are serial numbers (Jan 1 1900 = 1).
  • TODAY() and NOW() are volatile functions.

Common Mistakes

  • Subtracting text-dates resulting in #VALUE!.
  • Using TODAY() without freezing history.

Pro Tips

  • Paste-special values for snapshots.
  • Store holidays in a named range.

FAQ

What does this formula do in plain English?

The DATEDIF function calculates the exact elapsed time between two calendar dates in days, months, or years.

Why is my formula not working?

Subtracting text-dates resulting in #VALUE!.

Does this work in Google Sheets?

Yes, this syntax is fully compatible with Google Sheets.

What is the most common mistake?

Using TODAY() without freezing history.

Related Guides

How to Calculate WorkdaysHow to Extract Date ComponentsHow to Use TODAY and NOWExcel Error Hub

Need Complete Playbooks?

Download our verified manuals covering ERP Cleanup and Modeling.

Explore Playbook Series (From ₹199)