Having time associated with dates in Excel can sometimes throw off date calculations. Luckily, there is an easy way to strip out time data from any date.
Contents:
1. Removing Time from Date
2. Hiding Time from Date Formatting
How to Remove Time from a Date Using a Formula
We can turn the left table into the right table by applying the INT function to each date using the following formula:
= INT(date)
Because Excel stores dates as a whole number and times as the fractional part of a day (the decimal), the INT function will remove the decimal from each number.
For example, the datetime value 3/15/2023 10:30:00 AM can be represented as the number 44328.4375, where 44328 represents the number of days that have elapsed since January 1, 1900, and 0.4375 represents 10:30:00 AM (i.e., 43,750 seconds out of 86,400 seconds in a day).
When you use the INT function on a datetime value, it returns only the integer portion of the number. This effectively removes the fractional part of the number, which represents the time.
This can be easily seen when we apply a general formatting to the same dates. Before we use the INT function, the numbers on the left have trailing decimals. After using the INT function, the decimals are removed, and we are left with whole numbers.
How to Hide Time from a Date Using Formatting
If you would rather keep the time in each date, but just hide it from view instead, this can easily be accomplished by changing the date formatting.
Simply select the dates with the formatting you wish to change and select the pop-out button under Home > Number.
This will open up the Format Cells Menu.
Once the menu pops up, select the date format that you wish to use from the available type list. Selecting one without any time displayed will remove the time portion of your date from view.