Excel Add Subtract Months Days Years to Date
In this article
- Why Date Arithmetic in Excel Feels Tricky
- Adding or Subtracting Days: The Direct Method
- Adding or Subtracting Months: The EDATE Function
- Adding or Subtracting Years: Using EDATE with a Multiple of 12
- Combining Days, Months, and Years: The DATE Function
- Common Mistakes and How to Avoid Them
- Real-World Examples
- Frequently Asked Questions
This guide shows you how to add or subtract days, months, and years to a date in Microsoft Excel, covering the simple arithmetic method for days and the EDATE and DATE functions for months and years. You'll get step-by-step formulas, real examples, and common pitfalls to avoid.
Why Date Arithmetic in Excel Feels Tricky
Excel stores dates as serial numbers, where each whole number represents one day since January 1, 1900 (for Windows) or January 1, 1904 (for Mac). That means adding 7 to a date cell adds 7 days. But months and years have variable lengths—February has 28 or 29 days, months have 30 or 31—so you can't just add a fixed number. This is why Excel provides dedicated functions like EDATE and DATE to handle calendar logic correctly.
Adding or Subtracting Days: The Direct Method
To add or subtract days, simply use the plus or minus operator with a number. For example, if cell A1 contains 2025-03-15, then:
=A1+10gives March 25, 2025.=A1-45gives January 29, 2025.
You can also use the DATE function: =DATE(YEAR(A1), MONTH(A1), DAY(A1)+10). The direct method works because Excel treats dates as numbers, but be careful with negative results or dates before 1900—they'll show as ##### or a negative serial number.
Adding or Subtracting Months: The EDATE Function
The EDATE function handles month arithmetic correctly. Its syntax is EDATE(start_date, months). The second argument can be positive (future) or negative (past). For example:
=EDATE(A1, 3)adds 3 months.=EDATE(A1, -6)subtracts 6 months.
A key detail: if the start date is the last day of a month (e.g., January 31), EDATE returns the last day of the target month (February 28 or 29), not March 2 or 3. This is often what users expect, but it's worth knowing.
Adding or Subtracting Years: Using EDATE with a Multiple of 12
Since a year is 12 months, you can use EDATE with a multiple of 12. For example, to add 5 years: =EDATE(A1, 5*12). To subtract 10 years: =EDATE(A1, -10*12). This works perfectly for most cases, including leap days: adding 1 year to February 29, 2024 gives February 28, 2025 (since 2025 is not a leap year).
Combining Days, Months, and Years: The DATE Function
When you need to add or subtract a mix of days, months, and years, the DATE function is the most flexible. Its syntax is DATE(year, month, day). You can build the new date by extracting components and adding your offsets:
=DATE(YEAR(A1)+2, MONTH(A1)+3, DAY(A1)+15)adds 2 years, 3 months, and 15 days.=DATE(YEAR(A1)-1, MONTH(A1)-4, DAY(A1)-10)subtracts 1 year, 4 months, and 10 days.
The DATE function automatically normalizes overflow. For example, if you add 3 months to November 30, you get February 30, which Excel rolls over to March 2. This is different from EDATE, which clamps to month-end. Choose based on your business logic.
Common Mistakes and How to Avoid Them
- Using EDATE for days: EDATE only works with whole months; using a decimal like 0.5 will round down to 0 months. For days, use simple addition or DATE.
- Not formatting the result as a date: If the result shows a number like 45678, right-click the cell, choose Format Cells, and pick a date format.
- Ignoring leap years: Adding 1 year via
EDATEto Feb 29 gives Feb 28 in non-leap years. If you need Feb 29 to become Mar 1, you'd need a custom formula. - Negative dates: Dates before 1900 (or 1904 on Mac) are not supported; Excel will display
#####.
Real-World Examples
Suppose you have a project start date in A1 (2025-06-01) and you need to calculate:
- End date after 18 months:
=EDATE(A1, 18)→ 2026-12-01. - Review date 2 years and 3 months later:
=DATE(YEAR(A1)+2, MONTH(A1)+3, DAY(A1))→ 2027-09-01. - Deadline 45 days before:
=A1-45→ 2025-04-17.
Frequently Asked Questions
How do I add weeks to a date in Excel?
Multiply the number of weeks by 7 and add that to the date. For example, =A1+4*7 adds 4 weeks (28 days).
Can I add months and days in one formula without the DATE function?
Yes, but it gets messy. You could use =EDATE(A1, months) + days. This adds the months first, then the days. For example, =EDATE(A1, 2) + 15 adds 2 months and 15 days. Note that this is not the same as adding days first, because the number of days in the intermediate month matters.
Why does my formula return a number instead of a date?
Excel is showing the serial number. Select the cell(s), go to Home > Number Format, and choose a date format. You can also use =TEXT(A1+7, "mm/dd/yyyy") to force text, but that loses the date type.
How do I subtract months and get the same day-of-month?
Use EDATE. For example, =EDATE(A1, -3) gives the same day 3 months earlier, except when that day doesn't exist (like the 31st in a 30-day month), in which case it returns the last day of that month.
What is the difference between EDATE and DATE for month arithmetic?
EDATE clamps to the end of the month (Jan 31 + 1 month = Feb 28). DATE rolls over (Jan 31 + 1 month = Mar 3). Choose EDATE for month-end logic, DATE for exact day counts.
Can I add years and days without months?
Yes, use =DATE(YEAR(A1)+years, MONTH(A1), DAY(A1)+days). For example, =DATE(YEAR(A1)+1, MONTH(A1), DAY(A1)+30) adds 1 year and 30 days.