Excel stores time as a decimal number. (0.412) represents one hour which is 1/24. And to format a decimal value as a time you have two different ways to do it.
- Apply Time Format on the same cell.
- Create a new time value in the different cells.
Change Time Format using Custom Formatting
In the following example, you have a decimal value in cell A1, and now you need to apply the time format to this cell.
You can use the following steps to change the time format.
- First, use the keyboard shortcut Crtl + 1 to open the format option.
- After that, click on the time option from the list.
- Now, at the right side of the dialog box, select the time format that you want to apply.
- In the end, click OK to apply the format.
You can use any of the formats from the list of formats that you have in the format option dialog box.
Use TEXT Function to Change the Time Format
In Excel, there’s a TEXT function that you can use to change the format of time from to get it in a new cell with a new format. In the following example, you have a decimal value in cell A1.
And to change the time format, you need to use the TEXT function. You can use the following steps:
- First, in cell B1, enter the text function (=TEXT).
- After that, refer to cell A1.
- Next, in the second argument, specify the format that you want to apply to the time. Here we are using (hh:mm AM/PM).
- In the end, enter the closing parenthesis and hit enter to get the result.
Get the Excel File
- Back to the List of Excel Formulas