Type the function that would be entered into cell B7 to calculate the sum of cells B4 and B5

This tutorial explains the Excel SUMIF function in plain English. The main focus is on real-life formula examples with all kinds of criteria including text, numbers, dates, wildcards, blanks and non-blanks.

Microsoft Excel has a handful of functions to summarize large data sets for reports and analyses. One of the most useful functions that can help you make sense of an incomprehensible set of diverse data is SUMIF. Instead of adding up all numbers in a range, it lets you sum only those values that meet your criteria.

So, whenever your task requires conditional sum in Excel, the SUMIF function is what you need. A good thing is that the function is available in all versions, from Excel 2000 through Excel 365. Another great thing is that once you've learned SUMIF, it will take you very little effort to master other "IF" functions such as SUMIFS, COUNTIF, COUNTIFS, AVERAGEIF, etc.

SUMIF in Excel - syntax and basic uses

The SUMIF function, also known as Excel conditional sum, is used to add up cell values based on a certain condition.

The function is available in Excel 365, Excel 2021, Excel 2019, Excel 2016, Excel 2013, Excel 2010, Excel 2007, and lower.

The syntax is as follows:

SUMIF[range, criteria, [sum_range]]

As you see, the SUMIF function has 3 arguments - first 2 are required and the last one is optional.

  • Range [required] - the range of cells to be evaluated by criteria.
  • Criteria [required] - the condition that must be met. It may be supplied in the form of a number, text, date, logical expression, a cell reference, or another Excel function. For example, you can enter the criteria such as "5", "cherries", "10/25/2014", "10". Cell references should be used without the quotation marks, otherwise they would be treated as text strings.

    Basic SUMIF formula

    To better understand the SUMIF syntax, consider the following example. Suppose you have a list of products in column A, regions in column B, and sales amounts in column C. Your goal is to get a total of sales for a specific region, say North. To have it done, let's build an Excel SUMIF formula in its simplest form.

    You start with defining the following arguments:

    • Range - a list of regions [B2:B10].
    • Criteria - "North" or a cell containing the region of interest [F1].
    • Sum_range - the sales amounts to be added up [C2:C10].

    Putting the arguments together, we get the following formula:

    =SUMIF[B2:B10, "north", C2:C10]

    or

    =SUMIF[B2:B10, F1, C2:C10]

    Both formulas only sum sales in the North region:

    Note. The sum_range parameter actually defines only the upper leftmost cell of the range to be summed. The remaining area is defined by the dimensions of the range argument. In practice, this means that sum_range argument does not necessarily have to be of the same size as range argument, i. e. it may have a different number of rows and columns. However, the top left cell must always be the right one. For example, in the above formula, you can supply C2, or C2:C4, or even C2:C100 as the sum_range argument, and the result will still be correct. However, the best practice is to provide equally sized range and sum_range.

    Note. The SUMIF function is case-insensitive by nature. However, it is possible to force it to recognize the text case. For full details, please see Case-sensitive SUMIF in Excel.

    How to use SUMIF in Excel - formula examples

    Hopefully, the above example has helped you gain some basic understanding of how the function works. Below you will find a few more formulas that demonstrate how to use SUMIF in Excel with various criteria.

    SUMIF greater than or less than

    To sum numbers greater than or less than a particular value, configure the SUMIF criteria with one of the following logical operators:

    • Greater than [>]
    • Greater than or equal to [>=]
    • Less than [,

Chủ Đề