Excel Tutorial
Excel tutorials, quizzes & AI guides — all levels
RSS
  • Online Excel Exercises
  • Training
  • Excel Tests
  • Sitemap
  • Premium Quizzes
  • Shop
  • My account

How to Use the SUMIF Function in Excel

Conditional
Reading time: 2 minutes
Views: 17,777

The SUMIF function in Excel calculates the sum based on a specific product, region, or name as a condition.

However, many Excel users struggle to set the function correctly and often make mistakes. Let’s learn how to write and use the SUMIF function to analyze data efficiently.

🔗 At the end of this article, you will find links to test your understanding of the function.

Writing the SUMIF Function

The syntax for the SUMIF function is simple, but understanding each argument is essential to avoid errors.

  1. Range: The cells to check for the condition (criteria).
  2. Criteria: The condition or rule to match, such as a region or product name.
  3. Sum_range (optional): The cells to sum if the condition is met.

=SUMIF(range, criteria, [sum_range])

Examples of the SUMIF Function

For example, let’s calculate the Sales amount for the North region. How do we write this function?

  • First, focus on the condition or criteria.
  • Start by selecting the column containing the criteria, such as Area.
  • Next, define the value of the criteria, for example, North.
  • Then, select the column with the values to sum, like the Total column.
  • 💡Remember, the last argument must always point to the column with the values to sum.
Sales Total for North Region with SUMIFS function

In this situation, the function

  1. Read the column Area
  2. For the value North
  3. And add each value for the criteria North: 22 + 29.4 + 33.2 = 84.6

Now, if we want to calculate the Sales amount for Apricot, this time, we will write

  1. The Fruits column
  2. The criteria Apricot
  3. And still the same column to add, the Total
SUMIF to calculate the sum for Apricot

Last example, you can also use logical operators (greater, lower) to write your criteria. For instance, if you want to calculate the sum of the sales for July, you can write this function

SUMIF for dates before to the 1st august

Practise SUMIF online

Now write your own SUMIF formulas, directly in your browser. A portfolio of 15 sales: calculate the total by salesperson, by region and by product, in 6 steps, free and corrected as you type:

SUMIF Exercise - Total sales by salesperson, region or product

Total up a sales portfolio by salesperson, region and product using SUMIF, both with a fixed value and with a cell reference — 6 guided steps.

=SUMIF( criteria_range , "criteria" , sum_range )

1 / 6

You have a portfolio of 15 sales with the salesperson, the client, the region, the product and the amount.
In G2, calculate the total revenue of Martin. Type the name in full inside the formula.

SUMIF Sales — Q1 · 569

=SUMIF(A2:A16,"Martin",E2:E16)

=SUMIF( criteria_range , cell , sum_range )

2 / 6

In G2, calculate the total revenue of Dubois. Cell G1 holds the name of the salesperson — use that cell reference.

SUMIF Sales — Q2 · 570

=SUMIF(A2:A16,G1,E2:E16)

=SUMIF( criteria_range , "criteria" , sum_range )

3 / 6

Total revenue for the North region

SUMIF Sales — Q3 · 571

=SUMIF(C2:C16,"North",E2:E16)

=SUMIF( criteria_range , cell , sum_range )

4 / 6

In G2, calculate the total revenue of the South region. Cell G1 holds the criteria — use that reference.

SUMIF Sales — Q4 · 572

=SUMIF(C2:C16,G1,E2:E16)

=SUMIF( criteria_range , "criteria" , sum_range )

5 / 6

Total revenue for Pro License

SUMIF Sales — Q5 · 573

=SUMIF(D2:D16,"Pro License",E2:E16)

=SUMIF( criteria_range , cell , sum_range )

6 / 6

In G2, calculate the total revenue generated by Training. Cell G1 holds the criteria — use that reference.

SUMIF Sales — Q6 · 574

=SUMIF(D2:D16,G1,E2:E16)

Your score is

0%

👉 One more, with an operator, as in the last example above: in cell G2, add up the amounts greater than $3,000. This is a real spreadsheet: type in it as you would in Excel.

SUMIF Operators — Q1 · 575

The answer is =SUMIF(E2:E16,”>3000″). The operator and the number are written together, between double quotes.

Related articles

  • Step-by-step guide for SUMIF function
  • Training with the SUMIF and SUMIFS functions
  • Test Your Skills with COUNTIF and COUNTIFS
  • SUMIF vs SUMIFS in Excel: The Trap of the Argument Order

GROUPBY function can replace SUMIF

If you have difficulties writing the SUMIF function correctly, you can use the new GROUPBY function of Excel 365. Not only is this new function easier to write, but it also calculates the sum for each item of the column. GROUPBY can replace SUMIF for exact criteria match, not for lower or greater criteria.

GROUPBY can replace SUMIF

Frédéric LE GUEN

GROUPBY, SUMIF

Leave a Reply Cancel reply

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

Most Viewed Posts

  • Displaying Negative Numbers in Parentheses in Excel (310,065)
  • Top 10 Excel Functions You Must Know (232,001)
  • How to make automatic calendar in Excel (212,775)
  • Dash for a zero in Excel automatically (190,813)
  • Converting a Date from YYYYMMDD to DD/MM/YYYY in Excel (171,034)
image excel exercises
Excel Exercises
image excel quizzes
Excel Quizzes

How to Use the SUMIF Function in Excel

Reading time: 2 minutes
Views: 17,777

The SUMIF function in Excel calculates the sum based on a specific product, region, or name as a condition.

However, many Excel users struggle to set the function correctly and often make mistakes. Let’s learn how to write and use the SUMIF function to analyze data efficiently.

🔗 At the end of this article, you will find links to test your understanding of the function.

Writing the SUMIF Function

The syntax for the SUMIF function is simple, but understanding each argument is essential to avoid errors.

  1. Range: The cells to check for the condition (criteria).
  2. Criteria: The condition or rule to match, such as a region or product name.
  3. Sum_range (optional): The cells to sum if the condition is met.

=SUMIF(range, criteria, [sum_range])

Examples of the SUMIF Function

For example, let’s calculate the Sales amount for the North region. How do we write this function?

  • First, focus on the condition or criteria.
  • Start by selecting the column containing the criteria, such as Area.
  • Next, define the value of the criteria, for example, North.
  • Then, select the column with the values to sum, like the Total column.
  • 💡Remember, the last argument must always point to the column with the values to sum.
Sales Total for North Region with SUMIFS function

In this situation, the function

  1. Read the column Area
  2. For the value North
  3. And add each value for the criteria North: 22 + 29.4 + 33.2 = 84.6

Now, if we want to calculate the Sales amount for Apricot, this time, we will write

  1. The Fruits column
  2. The criteria Apricot
  3. And still the same column to add, the Total
SUMIF to calculate the sum for Apricot

Last example, you can also use logical operators (greater, lower) to write your criteria. For instance, if you want to calculate the sum of the sales for July, you can write this function

SUMIF for dates before to the 1st august

Practise SUMIF online

Now write your own SUMIF formulas, directly in your browser. A portfolio of 15 sales: calculate the total by salesperson, by region and by product, in 6 steps, free and corrected as you type:

SUMIF Exercise - Total sales by salesperson, region or product

Total up a sales portfolio by salesperson, region and product using SUMIF, both with a fixed value and with a cell reference — 6 guided steps.

=SUMIF( criteria_range , "criteria" , sum_range )

1 / 6

You have a portfolio of 15 sales with the salesperson, the client, the region, the product and the amount.
In G2, calculate the total revenue of Martin. Type the name in full inside the formula.

SUMIF Sales — Q1 · 569

=SUMIF(A2:A16,"Martin",E2:E16)

=SUMIF( criteria_range , cell , sum_range )

2 / 6

In G2, calculate the total revenue of Dubois. Cell G1 holds the name of the salesperson — use that cell reference.

SUMIF Sales — Q2 · 570

=SUMIF(A2:A16,G1,E2:E16)

=SUMIF( criteria_range , "criteria" , sum_range )

3 / 6

Total revenue for the North region

SUMIF Sales — Q3 · 571

=SUMIF(C2:C16,"North",E2:E16)

=SUMIF( criteria_range , cell , sum_range )

4 / 6

In G2, calculate the total revenue of the South region. Cell G1 holds the criteria — use that reference.

SUMIF Sales — Q4 · 572

=SUMIF(C2:C16,G1,E2:E16)

=SUMIF( criteria_range , "criteria" , sum_range )

5 / 6

Total revenue for Pro License

SUMIF Sales — Q5 · 573

=SUMIF(D2:D16,"Pro License",E2:E16)

=SUMIF( criteria_range , cell , sum_range )

6 / 6

In G2, calculate the total revenue generated by Training. Cell G1 holds the criteria — use that reference.

SUMIF Sales — Q6 · 574

=SUMIF(D2:D16,G1,E2:E16)

Your score is

0%

👉 One more, with an operator, as in the last example above: in cell G2, add up the amounts greater than $3,000. This is a real spreadsheet: type in it as you would in Excel.

SUMIF Operators — Q1 · 575

The answer is =SUMIF(E2:E16,”>3000″). The operator and the number are written together, between double quotes.

Related articles

  • Step-by-step guide for SUMIF function
  • Training with the SUMIF and SUMIFS functions
  • Test Your Skills with COUNTIF and COUNTIFS
  • SUMIF vs SUMIFS in Excel: The Trap of the Argument Order

GROUPBY function can replace SUMIF

If you have difficulties writing the SUMIF function correctly, you can use the new GROUPBY function of Excel 365. Not only is this new function easier to write, but it also calculates the sum for each item of the column. GROUPBY can replace SUMIF for exact criteria match, not for lower or greater criteria.

GROUPBY can replace SUMIF
Tags: GROUPBYSUMIF

Frédéric LE GUEN

Leave a Reply Cancel reply

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

Contact us
About me 
Privacy Policy

© 2022 – 2026 – excel-tutorial.com. All Rights Reserved.
Excel Tutorial is managed by majordome du net

Contact us
About me 
Privacy Policy

© 2022 – 2026 – excel-tutorial.com. All Rights Reserved.
Excel Tutorial is managed by majordome du net