Count Dates Between Two Dates

Excel Formulas › Count

All versionsCOUNTIFS

To count how many dates fall within a period — orders this month, sign-ups between two dates — use COUNTIFS with a start and end boundary. Two conditions on the same column fence the window.


Quick formula: to count dates in A2:A10 between E1 (start) and E2 (end):
=COUNTIFS(A2:A10, ">="&E1, A2:A10, "<="&E2)
The first condition keeps dates on or after the start; the second keeps them on or before the end.

Functions used (tap for the full reference guide):

The example

Order dates; count how many fall in February.

ABDE
1Order dateWindowCount
21/28Feb 12
32/05Feb 28
42/19
53/02

The formula

Orders in February (between D2 and E2 dates):

=COUNTIFS(A2:A5, ">="&D2, A2:A5, "<="&E2) // Feb 5 and Feb 19 → 2

How it works

Two date conditions create the window:

  1. A2:A5, ">="&D2 keeps dates on or after Feb 1. The & joins the operator to the date cell.
  2. A2:A5, "<="&E2 keeps dates on or before Feb 28.
  3. COUNTIFS counts rows passing both — the two February dates → 2.
  4. Add another condition pair (e.g. region) to count dates in range and matching a category.

Try it: interactive demo

Live demo

Pick a start and end date; count how many of the sample dates fall inside.

Count:

Variations

Count dates in a month with EOMONTH

One start cell drives the whole month:

=COUNTIFS(A2:A10, ">="&E1, A2:A10, "<="&EOMONTH(E1,0))

Count dates after a date

Just one boundary:

=COUNTIF(A2:A10, ">="&E1)

Count dates in range AND a category

Add a third condition:

=COUNTIFS(A2:A10, ">="&E1, A2:A10, "<="&E2, B2:B10, "West")

Pitfalls & errors

Operators must be quoted and joined. Write ">="&E1, not ">=E1" (which compares to the literal text “E1”).

Text dates won’t compare. If the date column is left-aligned text, COUNTIFS returns 0. Convert to real dates first.

Times can exclude the end day. A date with a time stamp like Feb 28 3pm is still ≤ Feb 28? Only if you compare to end-of-day. Use < next-day or strip the time if rows have timestamps.

Practice workbook

📊
Download the free Count Dates Between Two Dates practice workbook
Dated orders with live COUNTIFS date-window counts, the month and category variants, plus 4 challenges with answers. No sign-up required.

Frequently asked questions

How do I count dates between two dates in Excel?
Use COUNTIFS with two conditions on the date column: =COUNTIFS(A2:A10, ">="&start, A2:A10, "<="&end). Join the operators to the date cells with &.
How do I count dates in a specific month?
Use the first-of-month and EOMONTH as boundaries: =COUNTIFS(A2:A10, ">="&E1, A2:A10, "<="&EOMONTH(E1,0)).
Why does my date count return 0?
Usually the dates are stored as text, or the operator isn't joined with &. Ensure real date values and use ">="&cell syntax.

Stop fighting formulas. Learn them in a day.

This recipe is one of hundreds of real-world formulas we teach. Our Excel Formulas & Functions class covers lookups, logic, text, and dynamic arrays hands-on — live in Dallas–Fort Worth, Houston, Austin, Oklahoma City, Denver, or online.

See the Formulas & Functions Class

Related formulas: Sum by month · COUNTIFS with multiple criteria · Count by day of week

Function references: COUNTIFS · COUNTIF