How to extract date from datetime in excel
Tutor 5 (55 Reviews)
Excel Tutor
Still stuck with a Excel question
Ask this expertAnswer
A datetime value in Excel contains both a date and a time component. Extracting only the date is possible through formulas, formatting, or functions, depending on your requirements.
1. Using the INT Function
The INT function removes the decimal portion of a number. In Excel, dates are stored as whole numbers and times as fractional numbers.
Steps:
-
Suppose the datetime is in cell
A1. -
Enter the formula:
=INT(A1)
-
Press Enter. The result will display the date without the time.
-
Format the cell as a date if needed:
-
Go to Home → Number → Short Date or Long Date.
-
2. Using the DATE Function with YEAR, MONTH, and DAY
This method reconstructs the date explicitly.
Steps:
-
Suppose the datetime is in cell
A1. -
Enter the formula:
=DATE(YEAR(A1), MONTH(A1), DAY(A1))
-
Press Enter. The formula returns the date only, ignoring the time component.
3. Changing the Cell Format to Date Only
Formatting the cell does not remove the time value but displays only the date.
Steps:
-
Select the cell or range containing datetime values.
-
Right-click and choose Format Cells.
-
In the Number tab, select Date.
-
Pick the desired date format and click OK.
4. Using TEXT Function to Convert to Date String
The TEXT function converts datetime to a date as text.
Steps:
-
Suppose the datetime is in cell
A1. -
Enter the formula:
=TEXT(A1, "mm/dd/yyyy")
-
Press Enter. The result will show the date as text.
Note: Using TEXT converts the date to text, so arithmetic operations like addition or subtraction will not work unless converted back to a date.
5. Using Flash Fill (Excel 2013 and Later)
Flash Fill can automatically extract patterns like dates from datetime entries.
Steps:
-
In a column next to the datetime values, type the date corresponding to the first datetime.
-
Go to Data → Flash Fill or press Ctrl + E.
-
Excel fills the rest of the column with dates extracted from the datetime values.
Key Notes
-
The INT and DATE functions preserve the value as a proper Excel date.
-
Formatting changes only the display without altering the underlying value.
-
TEXT is useful for display or exporting purposes.
This ensures correct extraction and usage in calculations like age, duration, or comparisons.
. Was this Helpful?Get Online Tutoring or Questions answered by Experts.
You can post a question for a tutor or set up a tutoring session
Answers · 1
Why is today function not working
Answers · 1
How to extract date from datetime in excel
Answers · 1
Why is the date value not working
Answers · 1
How to create a date formula
Answers · 1