TIMEVALUE
Parses a time string and returns its fractional-day serial value.
The Formualizer engine in this repository at 0.15.0 plus unreleased changes computes the example results. Known differences from Excel are listed on this page.
Syntax
=TIMEVALUE(time_text)
Arguments
| Argument | Type | Required | Default |
|---|---|---|---|
time_text | any | Required | — |
Remarks
- Supported formats include 24-hour and AM/PM text forms with optional seconds.
- Result is a fraction in the range
0.0..1.0and does not include a date component. - Because only a time fraction is returned, workbook date-system choice does not affect output.
Examples
Parse a time written with a 24-hour clock.
Formula =TIMEVALUE("14:35:27")
Expected result 0.607951388888889
Try this formula
This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.
Parse a time that uses an afternoon marker.
Formula =TIMEVALUE("2:35 PM")
Expected result 0.607638888888889
Try this formula
This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.
Parse midnight at the start of a day.
Formula =TIMEVALUE("00:00:00")
Expected result 0
Try this formula
This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.
The input must use a recognized time format.
Formula =TIMEVALUE("later")
Expected result #VALUE!
Try this formula
This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.
Parse 24-hour time
Formula =TIMEVALUE("14:30")
Expected result 0.604166666666667
Try this formula
This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.
Parse 12-hour AM/PM time
Formula =TIMEVALUE("02:30 PM")
Expected result 0.604166666666667
Try this formula
This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.
Related functions
FAQ
Does TIMEVALUE depend on the 1900 vs 1904 date system?
No. TIMEVALUE returns only a time fraction, so date-system selection does not change the result.