Excel practice › Excel functions › EOMONTH

EOMONTH in Excel: the last day of a month

EOMONTH returns the last day of a month: the month of the date you give it, or a month some number of months before or after. With a move-in date of 1/15/2026 in C2, =EOMONTH(C2,0) gives 1/31/2026.

The second argument counts months: 0 is the same month, 1 the next one, -1 the one before. Add 1 to the result and you have the first day of the following month.

Skip to the 3 exercises ↓

Syntax

=EOMONTH(start_date, months)

start_date
The date to start from: a cell that holds a date, or a date built with DATE. Only its month and year matter, not the day.
months
How many months to move before taking the month's last day: 0 stays in the same month, a positive number goes forward, a negative number goes back. Required. A number with decimals is cut down to its whole part.
Live exampleEnd of the move-in month
E2fx
ABCDE
1UnitTenantMove-inRentMonth end
22BOkafor1/15/202618501/31/2026
34ALindqvist2/10/20262100
41CRamirez3/23/20261675
53DChen4/30/20261950
65ANovak6/8/20262300

The months argument

For the date 1/15/2026:

EOMONTH knows how long each month is, leap years included: starting from a date in January 2028, one month forward gives 2/29/2028.

The first day of a month

A date is a number of days, so adding 1 to a date gives the next day. The day after the end of a month is the first day of the next one:

Live exampleFirst day of the next month
E2fx
ABCDE
1UnitTenantMove-inRentNext month
22BOkafor1/15/202618502/1/2026
34ALindqvist2/10/20262100
41CRamirez3/23/20261675
53DChen4/30/20261950
65ANovak6/8/20262300

Where it goes wrong: a number instead of a date

EOMONTH returns a date the way Excel stores it: a serial number, the count of days with January 1, 1900 as day 1. In a cell that isn't formatted as a date, that number is what you see:

Live exampleA serial number where a date should be
E2fx
ABCDE
1UnitTenantMove-inRentMonth end
22BOkafor1/15/2026185046053
34ALindqvist2/10/20262100
41CRamirez3/23/20261675
53DChen4/30/20261950
65ANovak6/8/20262300

The other slip is the months argument. EOMONTH(C2,1) is the end of next month, not of this one. For the month the date is in, the argument is 0.

Practice: 3 exercises

Type the formula in the box, press Enter. Clicking a cell inserts its address. Each answer is checked on the data you see and again on changed data, so a typed-in value won't pass.

Exercise 1Last day of the move-in month

In E2, return the last day of the month in which the tenant in row 2 moved in (the date in C2).

E2fx
ABCDE
1UnitTenantMove-inRentMonth end
22BOkafor1/15/20261850
34ALindqvist2/10/20262100
41CRamirez3/23/20261675
53DChen4/30/20261950
65ANovak6/8/20262300
Show the answer

=EOMONTH(C2,0) gives 1/31/2026.

0 months from the date in C2 is January itself, and EOMONTH returns its last day.

Exercise 2First rent due date

Rent for the first full month is due on the first day of the month after move-in. In E2, return that date for the tenant in row 2.

E2fx
ABCDE
1UnitTenantMove-inRentRent due
22BOkafor1/15/20261850
34ALindqvist2/10/20262100
41CRamirez3/23/20261675
53DChen4/30/20261950
65ANovak6/8/20262300
Show the answer

=EOMONTH(C2,0)+1 gives 2/1/2026.

Adding 1 to the last day of January gives the first day of February. The formula never needs to know how long the month is.

Exercise 3Days to bill in the first month

The first month is prorated: the tenant pays for every day from move-in through the end of that month, move-in day included. In E2, return that number of days for row 2.

E2fx
ABCDE
1UnitTenantMove-inRentDays billed
22BOkafor1/15/20261850
34ALindqvist2/10/20262100
41CRamirez3/23/20261675
53DChen4/30/20261950
65ANovak6/8/20262300
Show the answer

=EOMONTH(C2,0)-C2+1 gives 17.

January 31 minus January 15 is 16 days, and the move-in day itself makes 17. The same formula gives 19 for a February 10 move-in, because EOMONTH knows that February 2026 has 28 days.

Questions people ask

Why does EOMONTH return a number like 46053 instead of a date?

The number is the date. Excel stores every date as a serial number of days, and EOMONTH returns that number. Format the cell as a date (Ctrl+1, then Date) and 46053 shows as 1/31/2026.

How do I get the first day of the month in Excel?

Take the end of the previous month and add one day: =EOMONTH(A2,-1)+1. For the first day of the next month, =EOMONTH(A2,0)+1. =DATE(YEAR(A2),MONTH(A2),1) also returns the first day of the date's own month.

How do I get the number of days in a month?

Ask for the day number of the month's last day: =DAY(EOMONTH(A2,0)). For any date in February 2026 it returns 28.

What is the difference between EOMONTH and EDATE?

Both move a date by a number of months. EDATE keeps the day of the month: from 1/15/2026, =EDATE(A2,1) is 2/15/2026. EOMONTH always lands on the last day of the month: =EOMONTH(A2,1) is 2/28/2026.

Keep going

Lesson 7 is seven drills on a design studio's invoices: days between two dates, month-end due dates with EOMONTH, business days with NETWORKDAYS, and TEXT for month labels and amounts inside a sentence. It's part of Pro ($29 once for all three tracks, or $19 for the Excel track alone). Lessons 1 and 2 and the skills test are free.

Related

NETWORKDAYS function, with live examplesDATEDIF function, with live examplesTEXT function, with live examples#VALUE! error in Excel: meaning and fixesExcel date functions practice (Pro)Excel functions with live examplesExcel practice online

Written and tested by Nico, who builds SheetDrill (about). Every formula on this page ran through the engine that checks the exercises before the page was published. Checked against: Microsoft Support: EOMONTH function, EDATE function. Last checked November 2026.