How to use the SUMIF function in Excel to add matching values

SUMIF adds up numbers in one column only when the matching cells in another column meet a condition. It suits beginners who track sales, expenses or stock in a simple table. You need a spreadsheet with a label column and a number column.

Sumif in excel #tutorial #tannumam #exceltutorial #sumif #excelformula #exceltutorial #exceltricks, by Accounts Expert on YouTube. 1 min.

Video length
1 min
Time to do it
10 minutes
Difficulty
Easy
Steps
8

What you need

Steps

  1. Open your spreadsheet and check that one column holds the labels you want to test, such as product names, and another holds the numbers to add.

  2. Click an empty cell below or beside your table where you want the total to appear.

  3. Type =SUMIF( to start the formula. Excel will show a hint listing the three parts it expects.

  4. Select the range of label cells, for example B2:B50, and type a comma.

  5. Type the condition in quotes, such as "Coffee" or ">100", then add a comma.

  6. Select the range of number cells to add, for example C2:C50, and close the bracket.

  7. Press Enter. The cell shows the total of all numbers whose matching label meets your condition.

  8. Copy the formula down or across to total other labels, and use dollar signs like $B$2:$B$50 to lock the ranges.

Tips and common mistakes

Make both ranges the same size, or the totals will be wrong.

Put text conditions in double quotes and use wildcards like "Cof*" to match partial words.

For several conditions at once, use SUMIFS instead of nesting SUMIF.

Questions

What is the difference between SUMIF and SUMIFS?

SUMIF checks one condition. SUMIFS lets you add numbers only when two or more conditions are met, and it asks for the sum range first.

Why does my SUMIF return 0?

The usual causes are mismatched range sizes, a missing quote around a text condition, or extra spaces in the label cells.

Can I use SUMIF in Google Sheets?

Yes. Google Sheets uses the same SUMIF syntax with the range, criterion and sum range in that order.

This guide was drafted from the video's details and general task knowledge. It has not been checked against the full video. Check the video and relevant product instructions before following a procedure. Report a correction.

More in Money & Office

See all