# DATEVALUE function

This article describes the formula syntax and usage of the **DATEVALUE** function (function: A prewritten formula that takes a value or values, performs an operation, and returns a value or values. Use functions to simplify and shorten formulas on a worksheet, especially those that perform lengthy or complex calculations.) in Microsoft Excel.

## Description

The **DATEVALUE** function converts a date that is stored as text to a serial number that Excel recognizes as a date. For example, the formula **=DATEVALUE("1/1/2008")** returns 39448, the serial number of the date 1/1/2008.

** Note ** The serial number returned by the **DATEVALUE** function can vary from the preceding example, depending on your computer's system date settings.

The **DATEVALUE** function is helpful in cases where a worksheet contains dates in a text format that you want to filter, sort, or format as dates, or use in date calculations.

To view a date serial number as a date, you must apply a date format to the cell. Find links to more information about displaying numbers as dates in the **See Also** section.

## Syntax

DATEVALUE(date_text)

The DATEVALUE function syntax has the following arguments (argument: A value that provides information to an action, an event, a method, a property, a function, or a procedure.):

**Date_text**Required. Text that represents a date in an Excel date format, or a reference (cell reference: The set of coordinates that a cell occupies on a worksheet. For example, the reference of the cell that appears at the intersection of column B and row 3 is B3.) to a cell that contains text that represents a date in an Excel date format. For example, "1/30/2008" or "30-Jan-2008" are text strings within quotation marks that represent dates.

Using the default date system in Microsoft Excel for Windows, the ** date_text** argument must represent a date between January 1, 1900 and December 31, 9999. The

**DATEVALUE**function returns the #VALUE! error value if the value of the

**argument falls outside of this range.**

*date_text*If the year portion of the ** date_text** argument is omitted, the

**DATEVALUE**function uses the current year from your computer's built-in clock. Time information in the

**argument is ignored.**

*date_text*## Remarks

- Excel stores dates as sequential serial numbers so that they can be used in calculations. By default, January 1, 1900 is serial number 1, and January 1, 2008 is serial number 39448 because it is 39,447 days after January 1, 1900.
- Most functions automatically convert date values to serial numbers.

## Example

Use the embedded workbook shown here to work with examples of this function. You can inspect and change existing formulas, enter your own formulas, and read further information about how the function works.

To work in-depth with this workbook, you can download it to your computer and open it in Excel. For more information, see the article Download an embedded workbook from OneDrive and open it on your computer.