HOUR Function
Returns the hour from a time.
Category
Date & Time
Available in
All versions, Microsoft 365
Returns
A number from 0 to 23
Overview
HOUR returns the hour of a time on the 24-hour clock: 0 (midnight) to 23 (11 PM).
It's handy for grouping timestamps by hour — busiest call times, peak sales hours.
Syntax
=HOUR(serial_number) Explain
Arguments
| Argument | Required? | What it does |
|---|---|---|
| serial_number | Yes | A time, a date with a time, or time text such as "6:45 PM". |
Examples
Example 1 — Hour of each call
Northstar's support log records the time of each call.
B2fx=HOUR(A2)
| A | B | |
|---|---|---|
| 1 | Call time | Hour |
| 2 | 9:30 AM | 9 |
| 3 | 6:45 PM | 18 |
| 4 | 12:15 AM | 0 |
| 5 | 3/15/2026 2:20 PM | 14 |
=HOUR(A2) Explain
Example 2 — Count calls in the 2 PM hour
Compare the hour of every timestamp.
=SUMPRODUCT(--(HOUR(A2:A500)=14)) Explain
Common mistakes
- Durations over 24 hours. HOUR only returns 0–23. For total hours in a duration, use =A2*24.
Notes

Author
Kyle Stott
Certified Microsoft Excel Expert
Kyle has worked professionally with Microsoft Excel for over a decade and has consulted on and taught Excel best practices to over 400 companies across 30+ countries.