How to Separate the Date and Time from a Timestamp in Excel
Split order timestamps into a date with INT and a time with MOD, then assign late-night orders to the next business date.
You will learn to
- Extract the date from a timestamp
- Extract the time from a timestamp
- Shift a date based on a cutoff time
How it works
A timestamp such as 3/9/2026 11:52 PM is one number: the whole part is the date and the decimal part is the time. =INT(B2) keeps the whole number — the date — and =MOD(B2,1) keeps the remainder — the time. Format each result as a date or a time.
The same idea handles cutoff rules. If orders after 10 PM count toward the next day, add the two hours that remain until midnight before taking INT: =INT(B2+2/24). Anything from 10 PM onward tips into the next date.
=INT(B2)