Home › Excel functions › EOMONTH
EOMONTH in Excel: Last Day of the Month
EOMONTH ("end of month") returns the last day of a month, a given number of months before or after a date. It's the reliable way to work with month ends, payment terms and monthly reports.
In this guide
EOMONTH syntax
=EOMONTH(start_date, months)| Argument | What it means |
|---|---|
| start_date | Any date in the starting month. |
| months | 0 for the same month, 1 for next month, -1 for last month, and so on. |
The result is a date serial number; format the cell as a date (Ctrl+1) if you see something like 46356.
Examples
With November 12, 2026 in A2:
| Goal | Formula | Result |
|---|---|---|
| Last day of this month | =EOMONTH(A2, 0) | Nov 30, 2026 |
| Last day of next month | =EOMONTH(A2, 1) | Dec 31, 2026 |
| Last day of last month | =EOMONTH(A2, -1) | Oct 31, 2026 |
| First day of this month | =EOMONTH(A2, -1)+1 | Nov 1, 2026 |
| First day of next month | =EOMONTH(A2, 0)+1 | Dec 1, 2026 |
| Days in this month | =DAY(EOMONTH(A2, 0)) | 30 |
EOMONTH practice: try it yourself
Reading is one thing, typing it is another. Build the formula below step by step: the tips tell you what to type next, and you can click or drag across cells to add them, just like in Excel.
Task: Find the last day of the month of the invoice date, in B2: =EOMONTH(A2,0)
Monthly totals with SUMIFS
With any date of the month in F1, this adds up all sales in that month:
=SUMIFS(C2:C100, A2:A100, ">="&EOMONTH(F1,-1)+1, A2:A100, "<="&EOMONTH(F1,0))No need to know whether the month has 28, 30 or 31 days. See SUMIFS.
Payment terms: "end of month + 30"
An invoice payable 30 days after the end of the invoice month: =EOMONTH(A2, 0)+30. For an invoice dated November 12, 2026, that's December 30, 2026.
EDATE: add whole months
EDATE keeps the day number: =EDATE(A2, 3) returns February 12, 2027. If the day doesn't exist in the target month, EDATE uses the last day: =EDATE(DATE(2026,1,31), 1) returns February 28, 2026. Use EDATE for contract renewals, EOMONTH for month ends.
In practice: a month-end closing calendar
Finance closes the books on the last working day of each month. Column A holds any date in the month; two formulas give the deadline:
| A | B | C | |
|---|---|---|---|
| 1 | Month | Last day | Last working day |
| 2 | 1 Jan 2026 | Sat 31 Jan 2026 | Fri 30 Jan 2026 |
| 3 | 1 Feb 2026 | Sat 28 Feb 2026 | Fri 27 Feb 2026 |
| 4 | 1 Mar 2026 | Tue 31 Mar 2026 | Tue 31 Mar 2026 |
- B2:
=EOMONTH(A2, 0) - C2:
=WORKDAY(EOMONTH(A2, 0)+1, -1)
January and February 2026 end on a Saturday, so the books close on the Friday before. WORKDAY with -1 steps back from the first day of the next month to the nearest working day.
Keep learning
Frequently asked questions
Why does EOMONTH return a number?
Dates are stored as numbers. Format the cell as a date with Ctrl+1 › Date.
How do I get the first day of the month?
Use =EOMONTH(A2, -1)+1: the last day of the previous month, plus one day.
How do I get the month name?
Use =TEXT(A2, "mmmm") for "November" or "mmm" for "Nov".