HOUR Function


Purpose of the Function

The Excel HOUR function returns the hour component of a time as a number between 0-23. For example, with a time of 2:30 AM, HOUR will return 2. You can use the HOUR function to extract the hour into a cell.

Syntax

=HOUR (serial_number)

  • serial_number : This is the time from which you want to extract the hour. It can be a cell reference containing a time, a time entered directly into the function, or a function that returns a time.

Practical Example


Step -01: Call HOUR Function :

Select the Cell, Which You Want to Apply the Function and Write HOUR Function =HOUR in Selected Cell.



Step -02 : Enter HOUR Arguments :

We need to Select the cell Which you want to extract the Hour from the Time within the Brackets.



Step -03 : Hit The Enter Key :

After Entering the Function, we need hit The Enter Key, The Excel returns the Hour from The Selected Time Cell.



Step -04 : Drag or Double Click in the Plus Sign (+) :

If You Drag Your mouse In the Bottom of Right Corner F2 Cell You Are Able To See Plus Sign (+), If you Double Click in The Plus Sign (+) The Excel Automatically returns the Hour From The Selected Time Cells OR Click On Plus Sign (+) And Drag Up to Last Cell.



The HOUR function is useful when you need to isolate and work specifically with the hour portion of a time in Excel, such as analyzing data by hour, calculating time differences, or performing operations based on specific hours within a dataset.