Skip to main content

Sum if date is greater than or less than a specific date in Excel

When you need to sum cell values based on a given criteria, the SUMIF function is the best choice. In this article, we will learn how to use the SUMIF function to get the total value if date is greater than or less than a specific date in Excel.


Sum if date is greater than or less than a specific date

To sum the values if corresponding dates are greater than or less than a specific date, the SUMIF function can do you a favor, the generic syntaxes are:

Generic formula with hardcoded text:

=SUMIF(date_range,">"&DATE(year,month,day),sum_range)
  • date_range: The range of dates;
  • “>”: Indicates greater than the specific date;( A variety of logical operators can be used to your needs, such as “=”, “>”, “>=”, “<”, “<=” etc.)
  • Date(year, month, day): The DATE function combines these three different values (year, month and day numbers) and returns a valid date;
  • sum_range: The range with values that you want to sum.

Generic formula with cell reference:

=SUMIF(date_range , ">" & date_cell, sum_range)
  • date_range: The range of dates;
  • “>”: Indicates greater than the specific date;( A variety of logical operators can be used to your needs, such as “=”, “>”, “>=”, “<”, “<=” etc.)
  • date_cell: The specific date cell that you want to sum values based on;
  • sum_range: The range with values that you want to sum.

Take the above screenshot as an example, I want to add up all amount values with corresponding order dates that are greater than 10/15/2021.

Please copy or enter any one of the below formulas into a blank cell, and press Enter key to get the result:

=SUMIF($A$2:$A$12,">" &DATE(2021,10,15),$C$2:$C$12)              (Type the criteria manually)
=SUMIF($A$2:$A$12,">" &E2,$C$2:$C$12)                                       
(Use a cell reference)


Tips:

1. To sum values if corresponding dates are less than a specific date, please use the below formulas:

=SUMIF($A$2:$A$12,"<" &DATE(2021,10,15),$C$2:$C$12)             (Type the criteria manually)
=SUMIF($A$2:$A$12,"<" &E2,$C$2:$C$12)                                       
(Use a cell reference)

2. If you need to sum values that the dates are greater than or less than today’s date, you should apply the below formula:

=SUMIF($A$2:$A$12,"<"&TODAY(),$C$2:$C$12)                    (sum if less than today)
=SUMIF($A$2:$A$12,">"&TODAY(),$C$2:$C$12)                    
(sum if greater than today)

Relative function used:

  • SUMIF:
  • The SUMIF function can help to sum cells based on one criterion.

More articles:

  • Sum Values By Year In Excel
  • Supposing, you have a range of data which contains a list of dates and sale amounts, now you want to get the total amount based on given years as below screenshot shown. In Excel, the normal SUMIFS and SUMPRODUCT functions can help to solve this task quickly and easily. This tutorial will demonstrate how to use these two functions in details.

The Best Office Productivity Tools

Kutools for Excel - Helps You To Stand Out From Crowd

🤖 Kutools AI Aide: Revolutionize data analysis based on: Intelligent Execution   |  Generate Code  |  Create Custom Formulas  |  Analyze Data and Generate Charts  |  Invoke Kutools Functions
Popular Features: Find, Highlight or Identify Duplicates  |  Delete Blank Rows  |  Combine Columns or Cells without Losing Data  |  Round without Formula ...
Super VLookup: Multiple Criteria  |  Multiple Value  |  Across Multi-Sheets  |  Fuzzy Lookup...
Adv. Drop-down List: Easy Drop Down List  |  Dependent Drop Down List  |  Multi-select Drop Down List...
Column Manager: Add a Specific Number of Columns  |  Move Columns  |  Toggle Visibility Status of Hidden Columns  Compare Columns to Select Same & Different Cells ...
Featured Features: Grid Focus  |  Design View  |  Big Formula Bar  |  Workbook & Sheet Manager | Resource Library (Auto Text)  |  Date Picker  |  Combine Worksheets  |  Encrypt/Decrypt Cells  |  Send Emails by List  |  Super Filter  |  Special Filter (filter bold/italic/strikethrough...) ...
Top 15 Toolsets12 Text Tools (Add Text, Remove Characters ...)  |  50+ Chart Types (Gantt Chart ...)  |  40+ Practical Formulas (Calculate age based on birthday ...)  |  19 Insertion Tools (Insert QR Code, Insert Picture from Path ...)  |  12 Conversion Tools (Numbers to Words, Currency Conversion ...)  |  7 Merge & Split Tools (Advanced Combine Rows, Split Excel Cells ...)  |  ... and more

Kutools for Excel Boasts Over 300 Features, Ensuring That What You Need is Just A Click Away...

Description


Office Tab - Enable Tabbed Reading and Editing in Microsoft Office (include Excel)

  • One second to switch between dozens of open documents!
  • Reduce hundreds of mouse clicks for you every day, say goodbye to mouse hand.
  • Increases your productivity by 50% when viewing and editing multiple documents.
  • Brings Efficient Tabs to Office (include Excel), Just Like Chrome, Edge and Firefox.
Comments (0)
No ratings yet. Be the first to rate!
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations