Arrow left
Back to guides
Google Sheets Formulas

MAXIFS Function in Google Sheets: Explained

In this article, you will learn how to use the MAXIFS formula in Google Sheets.

What does the MAXIFS function do in Google Sheets?

The MAXIFS function in Google Sheets is a function that returns the maximum value in a range that meets multiple criteria. The MAXIFS formula is beneficial when searching a large amount of data for the largest value that meets the requirements.

You can do the same search with the IF, MAX, and ARRAYFORMULA functions, but they tend to be complicated if you have multiple criteria, whereas the MAXIFS formula allows you to build a relatively easy-to-follow formula.

Save hours formatting your next financial spreadsheet!
100+ templates, all free to use.
Free Spreadsheet Templates

How to insert the MAXIFS formula in Google Sheets

  • Type “=MAXIFS” or go to “Insert”“Function” (or directly navigate to the “Functions” icon)  “Statistical”“MAXIFS”.

  • Specify the range from which the formula finds the maximum value

  • Input the range to which the function applies a criterion, and then the criterion

  • Repeat the third step until you enter all criteria

  • Press the “Enter” key.

How to insert the MAXIFS function from the menu bar in Google Sheets

In the next section, we will discuss how to use the MAXIFS formula with examples.

Sheets tutorials availalble now in our free certificate program!
Learn basic and intermediate functions with digestible videos and instructions.
Enroll in LiveFlow Academy

How to use the MAXIFS function in Google Sheets

The general syntax of the MAXIFS formula is as follows:

=MAXIFS(range, criteria_range1, criterion1, [criteria_range2, …], [criterion2, …])

range: This is the range that the function searched for the maximum value.

criteria_range1: This is the range to which the formula applies “criterion1”. The function checks whether each item in the range satisfies “criterion1”.

criterion1: This is a condition to filter the range, such as an amount of revenue or region of sales.

criteria_range2 [Optional]: Similar to “criteria_range1”, you need to specify the range to which the formula applies “criterion2”. You can select the same range with “criteria_range1” or a different one.

criterion2 [Optional]: If you need to input “criteria_range2”, you must identify the standard for the range.

Note 1: If necessary, you can add more than two criteria and their ranges

Note 2: The formula gives you zero if none of the conditions is met. Range and all of the criterion ranges need to be the same size. Otherwise, the MAXIFS formula returns “#VALUE”.

Assume that you have a dataset containing information on your customers, such as customer ID, revenue amount, date, region, and age. You want to find the maximum revenue that meets the following conditions: sales recorded (i) after 5/1/2021, inclusive, (ii) in the “East” region, and (iii) by customers aged less than or equal to thirty.

How to use the MAXIFS function in Google Sheets with an example

Look at the formula in detail. Note we fill two pairs of optional arguments for the second and third criteria (and the ranges to which they are applied).

range: $D$3:$D$22 (the Revenue column)

criteria_range1: $E$3:$E$22 (the Date column)

criterion1: $D$24 (Criteria 1)

criteria_range2: $F$3:$F$22 (the Region column)

criterion2: $D$25 (Criteria 2)

criteria_range3: $G$3:$G$22 (the Age column)

criterion3: $D$26 (Criteria 3)

As you can see, once you enter the Revenue range, what you need to do is to input a range for a criterion and the criterion and repeat the process until you include all three conditions. Then the formula automatically returns 35000, the maximum revenue meeting the abovementioned requirements. 

When you use the MAXIFS function, though you can input conditions manually in the formula, we highly recommend that you use cell references as we do because they allow you to see the requirements clearly and change them easily later, if necessary.

If you still want to use manual inputs for the formula, don’t enclose directly input arguments with quotation marks as you do for other functions.

Turn Quickbooks Online data into a Google Sheets dashboard
100+ templates, update automatically, totally secure!
Book a Demo

Learn how to do this step-by-step in the video below 👇

Automate financial reporting with LiveFlow

Want to eliminate manual updates of your Excel & Google Sheets models?

Yes, show me how

Need help?

Our team is here to help you any time between 9am and 10pm EST.
Check Icon
Email us at: help@liveflow.io

Liked this article? Then you'll love the ones below