∑ifIntermediate

SUMIF and COUNTIF practice problems

SUMIF, COUNTIF and SUMIFS are behind almost every report: total sales for one region, the number of orders over $1,000, revenue for one product in one region. These exercises use a real orders table so you can see exactly which rows match.

11 exercises0/11
Start practicing →

Try it yourself

A live spreadsheet. Type a formula and press Enter to check it.

Exercise 1 of 11SUMIF

What was the total revenue from the North region?

Write your formula in the green cell, I2.

q1-orders.xlsx
fx
1DateRegionRepProductUnitsRevenue
2Jan 4, 2026NorthAvaLaptop3$3,600.00North revenue
3Jan 9, 2026SouthLeoMonitor5$1,250.00
4Jan 15, 2026NorthMayaLaptop2$2,400.00
5Jan 22, 2026EastSamKeyboard12$720.00
6Feb 3, 2026WestZoeMonitor4$1,000.00
7Feb 11, 2026NorthAvaKeyboard8$480.00
8Feb 19, 2026SouthIvyLaptop4$4,800.00
9Feb 27, 2026EastSamMonitor6$1,500.00
10Mar 6, 2026WestNoahLaptop1$1,200.00
11Mar 14, 2026NorthMayaMonitor7$1,750.00
12
13

Click a cell to add it to your formula, drag to select a range, or click a column letter for the whole column.

All 11 conditional math exercises

  1. 1

    Revenue for one region

    Free

    What was the total revenue from the North region?

  2. 2

    Count one product

    Free

    How many orders were for Laptops?

  3. 3

    Revenue for one rep

    Premium

    What was the total revenue for Maya?

  4. 4

    Orders over $1,000

    Premium

    How many orders had revenue over $1,000?

  5. 5

    Two conditions at once

    Premium

    What was the revenue from Monitors sold in the South region?

  6. 6

    COUNTIFS with a number

    Premium

    How many Laptop orders had 3 or more units?

  7. 7

    Average for one rep

    Premium

    On average, how many units did Sam sell per order?

  8. 8

    Wildcards

    Premium

    What was the total revenue from reps whose name starts with S?

  9. 9

    Smallest matching value

    Premium

    What was the revenue of the smallest Laptop order?

  10. 10

    Revenue for one month

    Premium

    What was the total revenue in March 2026?

  11. 11

    AVERAGEIFS

    Premium

    What was the average revenue of North orders with more than 2 units?

The conditional math functions, with examples

Every example runs on q1-orders.xlsx, the same sheet the exercises use, and the results are calculated from that data.

  • Adds the values in one range for the rows where another range matches a condition.

    SUMIF(range, criteria, [sum_range])

    Example

    =SUMIF(B2:B11, "North", F2:F11)returns$8,230.00
  • Counts the cells that match a condition, like a product name or a number above a limit.

    COUNTIF(range, criteria)

    Example

    =COUNTIF(D2:D11, "Laptop")returns4
  • SUMIF with as many conditions as you need. All of them must be true for a row to count.

    SUMIFS(sum_range, criteria_range1, criteria1, …)

    Example

    =SUMIFS(F2:F11, B2:B11, "North", D2:D11, "Laptop")returns$6,000.00
  • AVERAGEIF

    Averages only the values whose row matches a condition.

    AVERAGEIF(range, criteria, [average_range])

    Example

    =AVERAGEIF(B2:B11, "East", E2:E11)returns9

Common mistakes

  1. 1

    Putting the sum range in the wrong place

    SUMIF ends with the cells to add: SUMIF(range, criteria, sum_range). SUMIFS starts with them: SUMIFS(sum_range, criteria_range, criteria, …). Mixing the two orders up is the most common SUMIFS error.

  2. 2

    Writing a comparison outside the quotes

    The operator goes inside the quotes: ">1000". To compare with a cell, join the operator to it: ">"&H1. Writing ">H1" compares against the text "H1".

  3. 3

    Ranges of different sizes

    In SUMIFS, every criteria range must have the same number of rows as the sum range, or the formula returns #VALUE!. Select whole matching columns of the same table.