Split First and Last Name in Excel — With Examples (TEXTSPLIT, LEFT, FIND)
Learn how to split first and last name in Excel: TEXTSPLIT, LEFT and FIND formulas, middle names, Flash Fill and Text to...
Read Guide →You have a start date — a contract, a subscription, a probation period — and you need the date 3 months later, or 12 months later. Adding 30 days does not work, because months are 28, 29, 30 or 31 days long, and the error grows with every month you add. Excel has a function for this, EDATE, which adds whole months and handles the month lengths for you — including the trap everyone worries about, 31 January plus 1 month. This guide gives you that formula first, works it through on a renewals table you can check by hand, shows you the month-end version, EOMONTH, and fixes the one display problem that catches everyone, the serial number that looks like 45351 instead of a date.
Quick takeaway: use EDATE to add whole months — never add 30 days.
=EDATE(start_date, months) — keeps the same day of the month.=EOMONTH(start_date, months) — lands on the last day of the month.
Months are not all 30 days long, so adding 30 days drifts further from the right answer with every month.
Start date: 31 January 2024. Add 1 month the wrong way: 31 January + 30 days = 1 March 2024. The right answer is 29 February 2024 (2024 is a leap year). One month, and the wrong method is already 1 day out — and it is in the wrong month.
Add 6 months the wrong way: 31 January + 180 days = 29 July 2024. The right answer is 31 July 2024. Two days out, and the error grows with every month you add. That is why you need a function that counts months, not days. Adding days works fine for days — see the subtraction formula guide for how dates add and subtract like numbers — but months need EDATE.
=EDATE(start_date, months)
EDATE keeps the day from the start date. If the target month is shorter and has no such day, EDATE snaps to the last day of that month.
Start date in B, term in months in C, renewal in D with =EDATE(B2,C2):
| Client | Start Date (B) | Term (C) | Renewal =EDATE(B2,C2) (D) |
|---|---|---|---|
| Northwind Labs | 31 Jan 2024 | 1 | 29 Feb 2024 |
| Bluefin Media | 15 Mar 2024 | 12 | 15 Mar 2025 |
| Cedar Health | 6 May 2024 | 6 | 6 Nov 2024 |
| Harbor Foods | 3 Oct 2024 | 3 | 3 Jan 2025 |
| Summit Legal | 29 Nov 2024 | 12 | 29 Nov 2025 |
Check the first row: 31 January plus 1 month. February 2024 has no 31st, so EDATE stops at the last day of February — 29 February, because 2024 is a leap year. In a non-leap year the same formula gives 28 February. The day is kept everywhere else: 15 March plus 12 months is 15 March next year, 6 May plus 6 months is 6 November.
Two more details: negative months go backwards — =EDATE(B2,-6) is six months earlier. And decimals are cut off — =EDATE(B2,1.9) adds 1 month, not 2.
Sometimes you do not want the same day — you want the end of the month. Reporting periods, “pay by the end of the month”, payroll periods. That is EOMONTH:
=EOMONTH(start_date, months)
It works just like EDATE, except it jumps to the last day of the month. The day in the start date is not used.
| Start Date | =EOMONTH(B2,0) | =EOMONTH(B2,1) | =EOMONTH(B2,-1) |
|---|---|---|---|
| 15 Jan 2024 | 31 Jan 2024 | 29 Feb 2024 | 31 Dec 2023 |
The months argument is required, and 0 means the end of the current month. From 15 March 2024, EDATE with 1 month gives 15 April, and EOMONTH gives 30 April.
EOMONTH gets you the first day of a month in one step — find a month end and add 1 day:
| Goal | Formula | Result for 15 Mar 2024 |
|---|---|---|
| First day of next month | =EOMONTH(B2,0)+1 | 1 Apr 2024 |
| First day of this month | =EOMONTH(B2,-1)+1 | 1 Mar 2024 |
| First day of last month | =EOMONTH(B2,-2)+1 | 1 Feb 2024 |
And the number of days in a month: wrap EOMONTH in DAY. The last day’s number is the number of days in that month:
=DAY(EOMONTH(A2,0))
For February 2024 that gives 29 — a leap year, checked for you by Excel, not by memory.
Adding years: multiply by 12 inside EDATE. 10 years is 120 months:
=EDATE(A1,12*10)
Going backwards: use a negative number. 3 months before an expiry date:
=EDATE(expiry_date,-3)
A contract that ends the day before its renewal: a contract that starts on 15 March usually ends the day before its renewal date:
=EDATE(B2,C2)-1
For a 12-month contract starting 15 March 2024, that gives 14 March 2025 — the last day of the contract, not the first day of the next one.
Quarterly cut-offs: if reports are due every three months, one formula gives all the dates. Start 31 January 2027, =EOMONTH($B$2,3), =EOMONTH($B$2,6), =EOMONTH($B$2,9), =EOMONTH($B$2,12) gives 30 April 2027, 31 July 2027, 31 October 2027, 31 January 2028.
EDATE and EOMONTH return a date serial number — the number Excel uses to store a date. If the cell is formatted as General, you see a number like 45351 instead of a date. The value is right; the format is wrong.
Fix it: select the cell and press Ctrl+Shift+# (Windows) or Control+Shift+# (Mac), or right-click → Format Cells → Date. The number becomes a date. How the date then looks — 2/29/2024 or 29/02/2024 — depends on your regional settings.
| Mistake | What happens | Fix |
|---|---|---|
| You added 30 days instead of 1 month | The date drifts — 1 day out after 1 month, more after 6 | Use EDATE: =EDATE(A2,1) |
| You rebuilt the date with DATE and MONTH+1 | 31 January + 1 month becomes 3 March — DATE rolls the extra days into the next month | Use EDATE, which snaps to the month end |
| The answer looks like 45351 | The cell is formatted as General, not as a date | Press Ctrl+Shift+#, or Format Cells → Date |
| You used EOMONTH when you wanted the same day | You got the month end instead of the same day | Use EDATE for the same day, EOMONTH for the month end |
| You used EDATE when you wanted the month end | You got the same day instead of the month end | Use EOMONTH |
| You typed 1.9 months | EDATE cuts off the decimal — 1 month, not 2 | Use a whole number of months |
| You added months to a date stored as text | #VALUE! error | Convert the text to a real date first |
| You need the contract end, not the renewal | EDATE gives the renewal date, one day too late | Subtract 1: =EDATE(B2,C2)-1 |
How do I add months to a date in Excel? Use =EDATE(start_date, months). For example, =EDATE(A2,3) adds 3 months to the date in A2, keeping the same day of the month.
How do I add 1 month to a date in Excel? Use =EDATE(start_date,1). For 31 January 2024 that gives 29 February 2024; for 15 March 2024 it gives 15 April 2024.
What is the difference between EDATE and EOMONTH? EDATE keeps the same day of the month (15 March + 1 month = 15 April). EOMONTH lands on the last day of the month (15 March + 1 month = 30 April).
What happens when I add 1 month to 31 January? EDATE snaps to the last day of February: 28 February in a normal year, 29 February in a leap year. It does not roll over into March.
Why does my EDATE formula show a number like 45351? EDATE returns a date serial number and the cell is formatted as General. Press Ctrl+Shift+#, or Format Cells → Date, and the number becomes a date.
How do I add years to a date in Excel? Multiply by 12 inside EDATE: =EDATE(A1,12*10) adds 10 years.
How do I subtract months from a date? Use a negative number: =EDATE(A2,-3) gives the date 3 months earlier.
How do I get the first day of the month in Excel? Use =EOMONTH(A2,-1)+1 for the first day of the current month, or =EOMONTH(A2,0)+1 for the first day of next month.
That is the whole method: EDATE for the same day n months later, EOMONTH for the last day of the month n months later, and a date format when the answer looks like a number. It works for renewals, probation, payment terms and quarterly dates, and the only cases that need extra care are the 31st of a month landing in a shorter month — which EDATE handles for you — and the DATE rebuild, which does not. Try it on your own dates now, with the renewals table above, and when you need to go the other way — counting the months between two dates instead of adding them — the next guide to read is the months between two dates guide, which uses DATEDIF for exactly that job.
Learn how to split first and last name in Excel: TEXTSPLIT, LEFT and FIND formulas, middle names, Flash Fill and Text to...
Read Guide →Learn how to get the month and year from a date in Excel: month name, month number, quarter, first and last day...
Read Guide →Learn how to extract text after a character in Excel: TEXTAFTER and TEXTBEFORE, the last word, and the older FIND method.
Read Guide →