DATE function
Builds a real Excel date from separate year, month and day numbers, rolling over extra months or days automatically.
Available in All versions of Excel (Windows and Mac), Excel for Microsoft 365, Excel for the web
In every Excel versionWorks in Google Sheets
Syntax
DATE(year, month, day)| Argument | What it means | |
|---|---|---|
year | Required | The year, ideally as four digits such as 2026. Values 0–1899 are added to 1900, so 26 means 1926, not 2026. |
month | Required | The month number. 1–12 is normal; 13 rolls into January of the next year, 0 means December of the previous year, negative numbers go further back. |
day | Required | The day number. Values beyond the month's length roll into the next month; 0 gives the last day of the previous month. |
Returns: A date serial number (for example 46096 for 15 March 2026), which Excel shows as a date when the cell has a date format.
How DATE works
DATE is the safest way to create a date inside a formula. Instead of typing "15/03/2026" (which means different things in different countries), you give Excel three plain numbers — year, month, day — and it returns the matching date serial number. Use it whenever dates arrive in pieces: a year column and a month column in a report, a text code like 20260415 from an accounting export, or a fixed cut-off date inside an IF test.
Behind the scenes Excel stores every date as a count of days since 1 January 1900 (day 1), so 1 January 2026 is 46023. DATE does that arithmetic for you and is forgiving: if the month is 14 it moves on to February of the following year, and if the day is 0 it steps back to the last day of the previous month. That rollover makes DATE the engine behind many date tricks, such as "first day of next month" or "last day of February" without worrying about leap years.
If the cell shows a number like 46096 instead of a date, nothing is wrong — the cell is simply formatted as General. Apply a date format (Home > Number Format > Short Date, or Ctrl+1) to see it as a date.
Examples
1Combine year, month and day columns
| A | B | C | D | |
|---|---|---|---|---|
| 1 | Year | Month | Day | Date |
| 2 | 2026 | 3 | 15 | 2026-03-15 |
| 3 | 2026 | 11 | 2 |
Result: 2026-03-15
DATE joins the three numbers into one date value, serial 46096 (cell formatted as yyyy-mm-dd). Fill the formula down to convert the second row to 2026-11-02.
2First day of the following month
| A | B | |
|---|---|---|
| 1 | Invoice date | Next month starts |
| 2 | 2026-12-18 | 2027-01-01 |
Result: 2027-01-01
MONTH(A2)+1 gives 13. DATE treats month 13 as January of the next year, so the result moves into 2027 without any extra IF logic (cell formatted as yyyy-mm-dd).
3Turn a text code from an export into a date
| A | B | |
|---|---|---|
| 1 | Posting code | Date |
| 2 | 20260415 | 2026-04-15 |
Result: 2026-04-15
LEFT, MID and RIGHT cut the text into "2026", "04" and "15". DATE accepts those numeric texts and returns a real date that you can sort, filter and subtract (cell formatted as yyyy-mm-dd).
4Last day of February in any year
| A | B | |
|---|---|---|
| 1 | Year | Last day of Feb |
| 2 | 2028 | 2028-02-29 |
Result: 2028-02-29
Day 0 of March is the day before 1 March, i.e. the last day of February. 2028 is a leap year, so the result is the 29th (cell formatted as yyyy-mm-dd).
Common errors and how to fix them
| Error | Why it happens | Fix |
|---|---|---|
#NUM! | The year is below 0 or above 9999, or the result falls before 1 January 1900. | Check the year argument; use four-digit years. |
#VALUE! | One of the arguments is text that is not a number, such as "March". | Convert month names with MONTH(DATEVALUE("1 "&A2&" 2026")) or use a lookup table. |
Tips
- Always type four-digit years.
DATE(26,1,1)returns 1 January 1926, a classic source of wrong ages and due dates. - Hard-coded dates inside formulas are clearer as
DATE(2026,12,31)than as the serial46387, and they work in every regional setting. - Because of rollover,
DATE(YEAR(A2),MONTH(A2),DAY(A2)+30)adds 30 days, but for 'same day next month' use EDATE instead.
Questions
Why does my DATE formula show a five-digit number?
Excel stores dates as serial numbers. The formula is correct; format the cell as a date (Ctrl+1 > Date) to display it as one.
Can DATE handle month 13 or day 40?
Yes. Extra months roll into the next year and extra days roll into the next month, so DATE(2026,13,1) is 1 January 2027 and DATE(2026,1,40) is 9 February 2026.
Is DATE affected by my computer's regional date format?
No. Because you pass numbers rather than text, DATE(2026,3,4) is always 4 March 2026, whatever the locale.
Google Sheets
DATE also exists in Google Sheets and works the same way for everyday use, so the examples above work there too.
DATE in other languages
In a non-English version of Excel the function has a local name. Excel translates formulas automatically when a file is opened in another language.
| Language | Function name |
|---|---|
| Czech | DATUM |
| Danish | DATO |
| Dutch | DATUM |
| Finnish | PÄIVÄYS |
| German | DATUM |
| Hungarian | DÁTUM |
| Italian | DATA |
| Norwegian (Bokmål) | DATO |
| Polish | DATA |
| Portuguese (Brazil) | DATA |
| Portuguese (Portugal) | DATA |
| Russian | ДАТА |
| Spanish | FECHA |
| Swedish | DATUM |
| Turkish | TARİH |
Recipes that use DATE
- How to add months to a date in Excel
- How to calculate age in Excel
- How to convert a date to text in Excel
- How to convert text to a date in Excel
- How to get the first and last day of the month in Excel
- How to get the quarter from a date in Excel
- How to sum values between two dates in Excel
- How to sum values by month in Excel