Skip to content

Excel SUM, SUMIF, and SUMIFS

What are SUM Functions?

SUM functions in Excel are powerful tools that allow you to add up numbers in your spreadsheet based on various conditions. Let's explore each function using our sales dataset (found here) with columns for Transaction Date, Customer, Region, Product Category, Product, Quantity, Price per Unit, and Total Sales.

Basic SUM Function

The SUM function adds all numbers in a specified range. The syntax is:

=SUM(range)

Example using our dataset:

=SUM(G2:G10)

SUM_function

This formula adds all quantities in the Quantity column. If your data is in column G from rows 2 to 10, it will sum all the quantities together.

SUMIF Function

SUMIF adds numbers that meet a single condition. The syntax is:

=SUMIF(criteria_range, criteria, sum_range)

Example using our dataset:

=SUMIF(G2:G10, ">10")

SUMIF_function

This formula sums all quantities greater than 10 units. In our sample data, this would include the Table (19), Headphones (14), Jacket (16), Shoes (12), and Shirt (15) transactions.

Advanced SUMIFS Function

SUMIFS allows multiple conditions. The syntax is:

=SUMIFS(sum_range, criteria_range1, criteria1, [criteria_range2, criteria2], ...)

Example using our dataset:

=SUMIFS(G2:G10, E2:E10, "Books")
This formula sums quantities where the Product Category is "Books". In our sample data, this would specifically look at the Table transaction where Product Category is Books.

SUMIFS_function

Real-World Applications

Using our sample dataset, here are some other practical examples:

  • Regional Analysis:

    =SUMIF(C2:C10, "West", G2:G10)
    
    Sums quantities for all West region sales

  • Product Category Performance:

    =SUMIFS(G2:G10, D2:D10, "Clothing", C2:C10, "North")
    
    Sums quantities for clothing items sold in the North region

  • High-Value Transactions:

    =SUMIFS(G2:G10, F2:F10, ">100", D2:D10, "Furniture")
    
    Sums quantities for furniture items priced over $100

Note: The actual results will vary based on your specific dataset. The examples above use the structure shown in the sample spreadsheet.

When to Use SUM Functions vs Pivot Tables

While both SUM functions and pivot tables can analyze your data, each has its ideal use cases: Choose SUM Functions When:

  • You need automatic, real-time calculations that update with your data
  • You want simple, direct formulas that are easy to audit
  • You're building dynamic dashboards or reports that reference these calculations
  • You need very specific or complex conditions for your calculations

Choose Pivot Tables When:

  • You want interactive data exploration and analysis
  • You're working with large datasets where performance matters
  • You need multiple summary calculations viewable at once
  • Your users need to manipulate and analyze data dynamically