## How to use the SUMIF function

*Article updated on June 16, 2018*

The SUMIF function sums values based on a condition. The condition can be applied to the values being summed or to corresponding values in another column.

### Excel function syntax

SUMIF(*range*, *criteria*, [*sum_range*])

### Arguments

range |
Required. The cell range you want to check the condition against. |

criteria |
Required. A single condition to filter values you want to sum. |

[sum_range] |
Optional. The sum_range argument allows you to apply a condition to corresponding values. |

### Comments

You are allowed to use logical operators like:

- < less than
- > greater than
- = equal to
- <= less than or equal to
- >= greater than or equal to

You also have the option to use an asterisk * to perform wildcard operations and a question mark ? to match a single character.

If you need to apply multiple conditions or criteria I recommend the SUMIFS function.

### Examples using wildcards and question marks

The wildcard character * allows you to match one to multiple characters and the question mark matches a single character.

### Download excel *.xlsx file

### Article with the 'SUMIF' Function

The following article has a formula that contains the SUMIF function.

Sum values in a range where adjacent cell value equals a criterion

Question: How do I sum all values in a range where adjacent cell value equals a criterion? The criterion is […]### Functions in 'Math and trigonometry'

The SUMIF function function is one of many functions in the 'Math and trigonometry' category.