This guide covers the essential functions for handling dates and times in Excel, including syntax, descriptions, and common use cases.
1. Current Date & Time
Use these to timestamp your sheets or create dynamic headers.
| Function | Syntax | Description |
| TODAY | =TODAY() | Returns the current system date. Updates every time the sheet recalculates. |
| NOW | =NOW() | Returns the current system date and time. |
2. Creating Dates & Times
Use these when you have components (Year, Month, Day) in separate cells.
| Function | Syntax | Description |
| DATE | =DATE(year, month, day) | Combines three integers into a valid Excel date. |
| TIME | =TIME(hour, minute, second) | Combines three integers into a valid Excel time. |
| DATEVALUE | =DATEVALUE("date_text") | Converts a date stored as text into a serial number Excel recognizes. |
| TIMEVALUE | =TIMEVALUE("time_text") | Converts a time stored as text into a serial number. |
3. Extracting Components
Use these to pull specific parts out of a full date or time serial number.
| Function | Syntax | Description |
| DAY | =DAY(serial_number) | Returns the day of the month (1-31). |
| MONTH | =MONTH(serial_number) | Returns the month (1 for Jan, 12 for Dec). |
| YEAR | =YEAR(serial_number) | Returns the four-digit year. |
| WEEKDAY | =WEEKDAY(date, [type]) | Returns a number (1-7) representing the day of the week. |
| WEEKNUM | =WEEKNUM(date) | Returns the week number of the year (1-52). |
| HOUR | =HOUR(serial_number) | Returns the hour (0-23). |
| MINUTE | =MINUTE(serial_number) | Returns the minute (0-59). |
| SECOND | =SECOND(serial_number) | Returns the second (0-59). |
4. Date Calculations
Use these for project timelines, deadlines, and aging reports.
| Function | Syntax | Description |
| EDATE | =EDATE(start_date, months) | Returns a date a specific number of months before or after the start date. |
| EOMONTH | =EOMONTH(start_date, months) | Returns the last day of the month, X months away. |
| DATEDIF | =DATEDIF(start, end, "unit") | Calculates the difference between two dates in “Y”, “M”, or “D”. |
| NETWORKDAYS | =NETWORKDAYS(start, end, [holidays]) | Returns the number of whole working days between two dates (excludes weekends). |
| WORKDAY | =WORKDAY(start, days, [holidays]) | Returns a date that is X working days in the future or past. |
5. Pro Tips & Formatting
The “Serial Number” Logic
Excel stores dates as whole numbers and times as decimals:
1= January 1, 190045390= April 8, 20240.5= 12:00 PM (half of a day)
Common Custom Formats
To change how a date looks without changing the data, press Ctrl + 1 and use these codes:
- d : 1 (Day)
- dd : 01 (Day with leading zero)
- ddd : Mon (Short day name)
- dddd : Monday (Full day name)
- mmm : Jan (Short month name)
- mmmm : January (Full month name)
- yyyy : 2024 (Full year)
- [h]:mm:ss : Use brackets for durations over 24 hours (e.g., 36:12:00).
Essential Shortcuts
- Insert Current Date:
Ctrl+; - Insert Current Time:
Ctrl+Shift+; - Apply Date Format:
Ctrl+Shift+# - Apply Time Format:
Ctrl+Shift+@