ExcelStatisticalIntermediate

MAXIFS

Returns the maximum value among cells specified by a given set of conditions.

Read the syntaxReview worked examplesOpen the spreadsheet app
=MAXIFS(max_range, criteria_range1, criteria1, ...)

This static page keeps the function indexed for search, while the spreadsheet app handles interactive exploration and saved formulas.

What the function does

Overview

Returns the maximum value among cells specified by a given set of conditions.

MAXIFS is a statistical function that returns the maximum value among cells specified by one or more sets of conditions or criteria. Introduced in Excel 2019 and Office 365, it replaces the need for complex array formulas like MAX(IF(...)). A critical technical requirement is that the ange and all ange arguments must have identical dimensions and shape; mismatched ranges will trigger a #VALUE! error. The function supports logical operators (>, <, <>, =) and wildcards (*, ?) for text-based filtering. Best practices include using cell references for criteria to maintain dynamic models and ensuring that numerical data in the ange is not stored as text, which the function would ignore. If no cells meet the criteria, MAXIFS returns 0, which can be ambiguous if 0 is also a valid data point in your range.

Quick reference

Syntax

=MAXIFS(max_range, criteria_range1, criteria1, ...)

Inputs

Arguments

max_rangeRange to find max in
Example: C2:C100
criteria_range1Range to check
Example: A2:A100
criteria1Condition
Example: "Class A"

Formula patterns

Examples

1

Highest sales in a specific region

=MAXIFS(C2:C10, A2:A10, "North")
salesfiltering
2

Maximum score with multiple criteria

=MAXIFS(D2:D20, B2:B20, ">80", C2:C20, "A")
educationmulti-condition
3

Finding latest date for a specific task ID

=MAXIFS(B2:B50, A2:A50, E2)
project managementdates

Avoid these issues

Common Errors

1

#VALUE!

Cause: The size and shape of the max_range and criteria_range arguments are not the same.

Fix: Ensure all range references (e.g., A2:A100 and B2:B100) have the exact same starting and ending row/column numbers.

2

Returns 0 unexpectedly

Cause: No cells meet the criteria, or the cells meeting the criteria are empty or contain non-numeric data.

Fix: Check your criteria for typos and verify that the max_range contains actual numbers rather than numbers formatted as text.

Platform support

Compatibility

Excel 2019+Excel-first

Source: Microsoft Support

Common questions

Frequently Asked Questions

Returns the maximum value among cells specified by a given set of conditions.

ange: Range to find max in ange1: Range to check criteria1: Condition

#VALUE!: Ensure all range references (e.g., A2:A100 and B2:B100) have the exact same starting and ending row/column numbers. Returns 0 unexpectedly: Check your criteria for typos and verify that the ange contains actual numbers rather than numbers formatted as text.