## TIME Function – Google Sheets

The TIME function takes three numbers and converts them to a time. The hour is input as 0-24 and therefore therefore you don’t need to enter AM/PM.

## Syntax

`=TIME(hour,minute,second)`

`hour` Number that represents the hour (0-23).

`minute` Number that represents the minute (0-59).

`second` Number that represents the second (0-59).

## Related functions

DATE – In a similar way to the TIME function, DATE takes three numbers and converts them to a date.

## Errors

#VALUE! – The inputs are something that isn’t a valid time such as “The other day” or “Yester-yester-day”.

## Examples

### Live examples in Sheets

Go to this spreadsheet for the examples of the TIME function shown above that you can study and use anywhere you would like.

## TIMEVALUE Function – Google Sheets

The TIMEVALUE function converts a time to a fraction of 1. Google Sheets works with times as fractions of a number, not as text strings. This function converts times into their usable form. Noon would be .5 and 6 PM would be .75.

The function can be used with 12 hour AM/PM time or with 24 hour time. If a date and time is given to the function, the date will be ignored, but the time will be converted. To represent seconds, use a second colon. 5 minutes and 12 seconds would be “00:05:12” not “05:12”.

Remember that dates are really just saved as numbers by your spreadsheet with date formatting applied. The date must be in a valid format, so you have to use the DATE function, wrap it in quotes, or use a cell reference to a cell containing a date.

## Syntax

`=TIMEVALUE(time_text)`

`time_text` Text representation of a time.

## Related functions

DATEVALUE – Converts a date to a numeric value in a similar way as TIMEVALUE.

HOUR – Returns the hour value from a time

MINUTE – Returns the minute value from a time

SECOND – Returns the second value from a time

## Errors

#VALUE! – The inputs are something that isn’t a valid time such as “A minute ago” or “Then”.

#NUM – An input is a number but is not a valid time.

## Examples

### Video example

Below is an example of this function being used to create an employee timesheet.

### Live examples in Sheets

Go to this spreadsheet for the examples of the TIMEVALUE function shown above that you can study and use anywhere you would like.