No history yet

Understanding Excel Date and Time Functions

Dates Are Just Numbers

To work with dates and times in Excel, you first need to understand a surprising secret: Excel doesn't see them as text. It sees them as numbers. Specifically, it treats them as serial numbers.

This system starts with the number 1, which represents January 1, 1900. The number 2 is January 2, 1900, and so on. This continuous count allows you to perform math on dates. For example, if you want to find the date 10 days from now, you can just add 10 to today's date serial number.

Every whole number in Excel's date system represents a unique day.

What about time? Time is handled as a fraction of a day. Noon, which is halfway through the day, is represented as 0.5. 6:00 PM is 0.75, and a full 24 hours brings you back to the next whole number.

Date and TimeSerial Number
January 1, 1900, 12:00 PM1.5
January 2, 1900, 6:00 AM2.25
October 26, 2023, 12:00 AM45224.0
October 26, 2023, 6:00 PM45224.75

You usually won't see these numbers directly. Excel automatically formats them into readable dates and times. But knowing this system is key to understanding how date and time functions work.

Getting the Current Date and Time

Two of the most common functions you'll use are TODAY() and NOW(). They do exactly what their names suggest.

The TODAY() function returns the current date's serial number, formatted as a date. It doesn't take any arguments.

=TODAY()

This is useful for things like an invoice date that always needs to be current. Be aware that this function is volatile, meaning it will update to the current date every time you open the workbook or the sheet recalculates.

If you need the current date and time, use NOW().

=NOW()

Like TODAY(), NOW() is also volatile and will continuously update. It's perfect for creating timestamps to log when a specific action was taken in a spreadsheet.

Building Dates and Times Manually

Sometimes you don't need the current date, but need to construct a specific date or time from individual components. For this, you can use the DATE() and TIME() functions.

The DATE() function takes three arguments: year, month, and day. It then returns the serial number for that specific date.

=DATE(year, month, day)

For example, to get the date for July 4, 2024, you would write:

=DATE(2024, 7, 4)

This is especially helpful when your year, month, and day values are in separate cells and you want to combine them into a single, valid date.

Similarly, the TIME() function builds a time value from hour, minute, and second components.

=TIME(hour, minute, second)

To create a time value for 3:30 PM, you would use:

=TIME(15, 30, 0)

Note that Excel uses a 24-hour clock for the hour argument, so 3 PM is 15. This function is great for calculating time durations or scheduling tasks when the time components are stored separately.

Now, let's test your understanding of these foundational date and time functions.

Quiz Questions 1/6

How does Excel internally represent dates?

Quiz Questions 2/6

What is the primary difference between the TODAY() and NOW() functions?

With these functions, you can handle most basic date and time needs in Excel, from logging current timestamps to building specific dates for calculations.