Dates function
Excel EOMONTH function
EOMONTH returns the last day of the month, a set number of months away from a start date. Use it for month-end reporting, payment terms like "end of next month", and counting days in a month.
=EOMONTH(start_date, months)Arguments
start_date- Any date in the starting month.
months- 0 for the same month, 1 for next month, -1 for last month.
EOMONTH examples
Every result below was calculated from this sample sheet by the same spreadsheet engine the Cellwise app uses.
| A | B | C | |
|---|---|---|---|
| 1 | Invoice | Invoice date | Amount |
| 2 | INV-310 | 2026-01-12 | 940 |
| 3 | INV-311 | 2026-02-20 | 1200 |
| 4 | INV-312 | 2026-03-05 | 375 |
Result: Jan 31, 2026
The last day of the invoice month: January 31, 2026.
Result: Mar 31, 2026
Payment due at the end of next month: March 31, 2026.
Result: Mar 1, 2026
The end of last month plus one day is the first day of this month.
Result: 28
Reads the last day's number to count the days in February: 28.
How to use EOMONTH
- Click the cell for the result.
- Type =EOMONTH( and click any date.
- Type ,0 for this month or another number of months.
- Press Enter and format the cell as a date.
Common EOMONTH mistakes
Leaving out the months argument
EOMONTH needs both arguments. Use 0 for the current month.
Result shows as 46053
That is a date serial. Format the cell as a date.
Using it to add months while keeping the day
EOMONTH always jumps to month-end. Use EDATE to keep the same day.
EOMONTH FAQ
How do I get the last day of the month in Excel?
Use =EOMONTH(A2,0). It works for leap years and months of any length.
How do I get the first day of the month in Excel?
Use =EOMONTH(A2,-1)+1. It finds the end of the previous month and adds one day.
How do I calculate "end of month plus 30 days" payment terms?
Add the days to EOMONTH: =EOMONTH(A2,0)+30.
Practice EOMONTH in these lessons
Guides that use EOMONTH
Related functions
Updated