Skip to content
Free Excel Tutorials
  • Home
  • Excel For Beginners
  • Excel Intermediate
  • Advanced Excel For Experts

Data Analysis

  • How to conditionally sum numeric data in an Excel table using SUMIFS
  • Randomize/ Shuffle List in Excel
  • How to count table columns in Excel
  • Create Scatter Chart in Excel
  • How to create a Histogram in Excel

References

  • Count rows that contain specific values in Excel
  • How to use Excel LOOKUP Function
  • Extract all partial matches in Excel
  • Extract data with helper column in Excel
  • Lookup entire row in Excel

Data Validations

  • Excel Data validation exists in list
  • Excel Data validation specific characters only
  • Data validation must not exist in list
  • Excel Data validation don’t exceed total
  • Excel Data validation must contain specific text

Count times in a specific range in Excel

by

This tutorial shows how to Count times in a specific range in Excel using example below.

To count times that occur within a certain range, you can use the COUNTIFs function.

Formula

=COUNTIFS(range,">="&start,range,"<"&end)

Explanation

In the example shown, the formula in E7 is:

=COUNTIFS(B5:B11,">="&E5,B5:B11,"<"&E6)

How this formula works

The COUNTIFS function takes one or more criteria, entered as range/criteria pairs. In this example, the first range/criteria pair is:

B5:B11,">="&E5

Matching any time greater than or equal to the time E5 (5:00).

The second range/criteria pair is:

B5:B11,"<"&E6

Matching any time less than the time in E6 (6:30).

With hard-coded values

The formula in E7 could be written with hard-coded time values as follows:

=COUNTIFS(B5:B11,">=5:00",B5:B11,"<6:30")

Excel translates a string like “5:00” into the correct numeric time value.

With the TIME function

The formula in E7 could be written with the TIME function like this:

=COUNTIFS(B5:B11,">="&TIME(5,0,0),B5:B11,"<"&TIME(6,30,0))

The TIME function provides a simple way to assemble a valid time using discreet hour, minute, and second values.

Post navigation

Previous Post:

DECIMAL function: Description, Usage, Syntax, Examples and Explanation

Next Post:

AVERAGE function: Description, Usage, Syntax, Examples and Explanation

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Learn Basic Excel

Ribbon
Workbook
Worksheets
Format Cells
Find & Select
Sort & Filter
Templates
Print
Share
Protect
Keyboard Shortcuts

Categories

  • Charts
  • Data Analysis
  • Data Validation
  • Excel Functions
    • Cube Functions
    • Database Functions
    • Date and Time Functions
    • Engineering Functions
    • Financial Functions
    • Information Functions
    • Logical Functions
    • Lookup and Reference Functions
    • Math and Trig Functions
    • Statistical Functions
    • Text Functions
    • Web Functions
  • Excel VBA
  • Excel Video Tutorials
  • Formatting
  • Grouping
  • Others

Logical Functions

  • Nested IF function example in Excel
  • IF with wildcards in Excel
  • IFERROR function: Description, Usage, Syntax, Examples and Explanation
  • How to return blank in place of #DIV/0! error in Excel
  • Check multiple cells are equal in Excel

Date Time

  • NETWORKDAYS.INTL function: Description, Usage, Syntax, Examples and Explanation
  • Convert Excel time to decimal seconds
  • Assign points based on late time in Excel
  • NOW function: Description, Usage, Syntax, Examples and Explanation
  • Convert text to date in Excel

Grouping

  • Group times into unequal buckets in Excel
  • If cell contains one of many things in Excel
  • Group arbitrary text values in Excel
  • Calculate conditional mode with criteria in Excel
  • Group numbers at uneven intervals in Excel

General

  • Select, Insert, Rename, Move, Delete Worksheets in Excel
  • How to choose page/paper size in Excel before Printing
  • List sheet names with formula in Excel
  • Basic error trapping example in Excel
  • How to create dynamic named range with INDEX in Excel
© 2025 xlsoffice . All Right Reserved. | Teal Smiles | Abbreviations And Their Meaning