How to remove time from date in Excel?

Sometimes, when you import data into Excel, if there has a column of date with time stamp, such as 2/17/2012 12:23, and you don’t want to retain the time stamp and want to remove the time 12:23 from the date and only leave the date 2/17/2012. How could you quickly remove time from date in mulitple cells in Excel?

Remove time from date with Format Cells

Remove time from date with Find and Replace function

Remove time from date with Text to Columns function

Remove time from date with VBA code

Remove time from date with Kutools for Excel's Extract Text function


arrow blue right bubbleRemove time from date with Format Cells

1.Select the cells you want to remove time, and right click to show the context menu, and choose Format Cells. See screenshot:
doc remove time from datetime 1

2. In the Format Cells dialog, select Date from the Category list, and select one type of date as you need form right section. See screenshot:
doc remove time from datetime 2

3. Click OK, now the time has been removed from each date cell. See screenshot:
doc remove time from datetime 3


arrow blue right bubbleRemove time from date with Find and Replace function

1. Select the date range that you want to remove the time.

2. Click Home > Find & Select > Replace, and a Find and Replace dialog box will pop out. See screeenshot:

doc remove time from date1

3. Then enter a spacebar and a asterisk * into the Find what box. And leave blank in the Replace with box.

4. Click Replace All. And all of the time stamp have been removed in the date range. See screenshot:

doc-remove-time-from-date2

5. Then you can format the range to show only the date.


arrow blue right bubbleRemove time from date with Text to Columns function

With the function of Text to Columns, you can also remove time from the date. Please do as the following steps:

1. Highlight the range you need to delete the time stamps.

2. Click Data > Text to Columns, and a Convert Text to Columns Wizard will appear. See screenshot
:doc-remove-time-from-date3

3. Check Delimited, and click Next. Then check Space, and go on next.
doc-remove-time-from-date4

4. At last, click Finish. And the time have been isolated from the date. See screenshot:
doc-remove-time-from-date5

5. Then you can delete column D. And remember to format the date as you like.


arrow blue right bubbleRemove time from date with VBA code

The following VBA code can help you quickly to remove the time stamps from the date directly. Do as follows:

1. Select the range that you want to remove the time.

2. Click Developer>Visual Basic or press Alt + F11, a new Microsoft Visual Basic for applications window will be displayed, click Insert>Module, and input the following code into the Module:

VBA: Remove time from date.

Sub ConvertDates()
'Updateby20140529
Dim Rng As Range
Dim WorkRng As Range
On Error Resume Next
xTitleId = "KutoolsforExcel"
Set WorkRng = Application.Selection
Set WorkRng = Application.InputBox("Range", xTitleId, WorkRng.Address, Type:=8)
For Each Rng In WorkRng
    Rng.Value = VBA.Int(Rng.Value)
Next
WorkRng.NumberFormat = "mm/dd/yyyy"
End Sub

3. Then click doc-multiply-calculation-3 button to run the code. And a dialog pops out for selecting a range to remove the time from date. See screenshot:
doc-remove-time-from-date7

4. Click OK, and all of the time in selection have been deleted and the date format also have been set.
doc-remove-time-from-date6


arrow blue right bubbleRemove time from date with Kutools for Excel's Extract Text function

Actually, if you have Kutools for Excel -- a handy tool with more than 120 functions, you can apply its Extract Text function to quickly extract date only from the datetime cell.

Kutools for Excel, with more than 120 handy functions, makes your jobs easier. 

After installing Kutools for Excel, please do as below:(Free Download Kutools for Excel Now!)

1. Select the range cells you want to extract dates only, and click Kutools > Text > Extract Text. See screenshot:
doc remove time from datetime 4

2. In the Extract Text dialog, enter * and a space into the Text box, and click Add button to add it to the Extract list. See screenshot:
doc remove time from datetime 5

3. Click Ok, and a dialog pops out for you to select a cell to place the extracted date, see screenshot:
doc remove time from datetime 6

4. Click OK. Now all the dates are extracted from cells only.
doc remove time from datetime 7

Tip. If you want to have a free trial of the Extract Text function, please go to free download the Kutools for Excel first, and then go to apply the operation according above steps.


Related Articals:

How to remove year from date in Excel?

How to change multiple dates to day of week in excel?


Recommended Productivity Tools

Office Tab

gold star1 Bring handy tabs to Excel and other Office software, just like Chrome, Firefox and new Internet Explorer.

Kutools for Excel

gold star1 Amazing! Increase your productivity in 5 minutes. Don't need any special skills, save two hours every day!

gold star1 200 New Features for Excel, Make Excel Much Easy and Powerful:

  • Merge Cell/Rows/Columns without Losing Data.
  • Combine and Consolidate Multiple Sheets and Workbooks.
  • Compare Ranges, Copy Multiple Ranges, Convert Text to Date, Unit and Currency Conversion.
  • Count by Colors, Paging Subtotals, Advanced Sort and Super Filter,
  • More Select/Insert/Delete/Text/Format/Link/Comment/Workbooks/Worksheets Tools...

Screen shot of Kutools for Excel

btn read more      btn download     btn purchase

Add comment


Security code
Refresh