Excel Tutorials

How to Calculate Min and Max in Excel

MIN and MAX are two of the simplest functions in Excel and two of the most useful, once you go past the raw number and start returning the name attached to it. This lesson covers both functions, how blanks and a stray zero can quietly ruin a minimum, finding the second or third largest value, and adding conditions with MINIFS and MAXIFS. It uses the Event Planner workbook from Excel Foundations, free to download below.

Download the Event Planner Workbook

Follow along in the same file used in the video. No email required.

⬇ Event Planner Workbook (.xlsx)

What Do MIN and MAX Do in Excel?

MAX returns the largest number in a range and MIN returns the smallest. =MAX(D2:D20) and =MIN(D2:D20) is the entire syntax, and they are usually the first two functions people learn after SUM and AVERAGE.

Both ignore blank cells, text and logical values, exactly as AVERAGE does. That is normally helpful, but it produces one genuinely dangerous failure: if the largest number in your column arrived from an import as text rather than a number, MAX skips it and returns the second largest instead, with no error and nothing on screen to suggest anything is wrong.

The other trap is zeros. A blank is ignored, but a real 0 is a real value, so MIN returns 0 on any column containing one. If zero means "nothing submitted yet" rather than a genuine measurement, your minimum is describing a gap in the data instead of the data. Both problems, and how to work around them, are covered below.

How to Use MIN and MAX in Excel

Step-by-step, matching the video above.

1

Write MAX to find the largest value

=MAX(D2:D20) returns the biggest number in the range. Like AVERAGE, it ignores blank cells, text and logical values entirely rather than treating them as zero.

2

Write MIN to find the smallest

=MIN(D2:D20) returns the lowest number. The syntax is identical, which is why the two are always taught together.

3

Use the AutoSum dropdown to insert them by clicking

On the Home tab far right, or the Formulas tab, click the arrow beside AutoSum and pick Max or Min. Check the range Excel guessed before you press Enter, since it assumes the block directly above your cursor.

4

Cover several ranges or loose cells

=MAX(D2:D10,F2:F10,25) works fine. Arguments can be ranges, individual cells, or literal numbers mixed together, and MIN behaves the same way.

5

Read them off the status bar for a quick look

Select a range and the status bar can display Min and Max alongside Average, Count and Sum. They are not shown by default, so right-click the status bar and tick Minimum and Maximum once, and they stay on from then on.

6

Return the label instead of the number

The largest value is rarely the whole question. =XLOOKUP(MAX(D2:D20),D2:D20,A2:A20) returns who or what that maximum belongs to, pulling the name from column A. On older Excel use =INDEX(A2:A20,MATCH(MAX(D2:D20),D2:D20,0)).

7

Find the second or third largest with LARGE and SMALL

=LARGE(D2:D20,2) gives the second highest value and =SMALL(D2:D20,3) the third lowest. LARGE(range,1) is identical to MAX, so these are the general form of both functions.

8

Add a condition with MINIFS and MAXIFS

=MAXIFS(D2:D20,B2:B20,"Gold") returns the highest value among Gold-tier rows only. The value range comes first, then pairs of criteria range and criteria. Both need Excel 2019 or Microsoft 365.

Turn on Minimum and Maximum in the status bar once and you will use them constantly. Right-click the bar along the bottom, tick both, and every range you select from then on shows its high and low without a single formula.
What MIN and MAX Ignore, and Why It Matters

The same blanks-and-text behaviour as AVERAGE, with one consequence that catches people out badly.

Blank cells are skipped, not read as zero

An empty cell has no effect on either function. A column of positive numbers with gaps still returns the smallest actual number, not 0.

A real zero is a real value

If any cell genuinely contains 0, MIN returns 0. On a column where zero means "not submitted yet" rather than a true measurement, this makes the minimum meaningless. Use =MINIFS(D2:D20,D2:D20,">0") to exclude zeros.

Text is ignored completely

Numbers stored as text are invisible to both functions. If the true maximum arrived from an import as text, MAX will confidently return the second-largest value with no error at all, which is the most dangerous failure mode here.

Formulas returning empty text behave like blanks

A formula ending ,"") produces text, so MIN and MAX skip it. Useful, but only if you know it, since it looks identical to an empty cell on screen.

MINA and MAXA count text and logicals

MINA and MAXA treat text as 0 and FALSE as 0, TRUE as 1. MINA on a column containing any text will therefore return 0, which is almost never the intention.

Negative numbers are where zeros bite hardest

On a column of profit and loss figures containing both negatives and a stray zero, MIN returns the most negative number correctly. But on a column of all-positive values, one zero silently becomes the minimum.

Worked Example: Highest and Lowest Event Spend
FormulaWhat It AsksResult
=MAX(D2:D6)Largest spend620.00
=MIN(D2:D6)Smallest spend150.00
=LARGE(D2:D6,2)Second largest480.00
=SMALL(D2:D6,2)Second smallest210.00
=XLOOKUP(MAX(D2:D6),D2:D6,A2:A6)Who spent the mostNortheast
=MAXIFS(D2:D6,B2:B6,"Gold")Highest Gold-tier spend620.00
=MAX(D2:D6)-MIN(D2:D6)The spread across the group470.00

Row five is the one that changes how useful these functions are. MAX on its own tells you the number 620 exists somewhere; wrapping it in XLOOKUP tells you it belongs to the Northeast, which is the thing anyone reading the report actually wanted to know. The last row is the other habit worth forming: max minus min gives you the range, and a wide spread often says more about your data than either endpoint alone.

Practical Uses Beyond the Obvious

Where MIN and MAX earn their place inside larger formulas.

Capping and flooring a value

=MIN(D2,1000) caps a figure at 1000 no matter how large it gets, and =MAX(D2,0) stops a result going negative. Nesting them, =MIN(MAX(D2,0),1000), constrains a value to a range in one line, which is far cleaner than a nested IF.

Finding the earliest and latest date

Dates are numbers underneath, so =MIN(C2:C20) gives the earliest date and =MAX(C2:C20) the latest. Format the result cell as a date, or it will display as a five-digit serial number.

Highlighting the top and bottom rows automatically

Home > Conditional Formatting > Top/Bottom Rules colours the highest or lowest values without any formula. For full control, use a formula rule of =D2=MAX($D$2:$D$20).

Building a range summary block

Count, min, max, average and median stacked in five cells beside a data set describes the whole distribution in about thirty seconds, and reveals problems, such as a minimum of zero, that a single number would hide.

Where to Find MIN and MAX

Three routes, same result.

The AutoSum dropdown

Home tab far right, or Formulas > AutoSum. Click the arrow rather than the button itself and choose Max or Min from the list.

The Function Library

Formulas > More Functions > Statistical holds MIN, MAX, MINA, MAXA, MINIFS, MAXIFS, LARGE and SMALL together in one alphabetical list.

The status bar

Right-click the bar at the bottom of the Excel window and tick Minimum and Maximum. They then appear for every range you select, with no formula involved.

Common MIN and MAX Mistakes to Avoid

⚠️

MIN returning 0 because of a placeholder zero

A cell holding 0 as a stand-in for missing data becomes the minimum on any all-positive column. Use =MINIFS(D2:D20,D2:D20,">0") to exclude zeros, or leave those cells genuinely blank.

⚠️

The real maximum being stored as text

Numbers imported as text are invisible to MAX, so it quietly returns the second-largest value with no error. Compare the status bar Count against your row count, and convert with Text to Columns if they differ.

⚠️

Including the header row in the range

Harmless with text headers, which are ignored, but a header like the year 2026 is a number and will be returned as the maximum. Start the range at the first data row.

⚠️

Including the result cell in its own range

Putting =MAX(D2:D20) inside D20 creates a circular reference and returns 0 once Excel gives up on it.

⚠️

Reporting the number without the name

The maximum value alone rarely answers the question. Wrap it in XLOOKUP or INDEX/MATCH to return which row it belongs to, since that is what people actually want to know.

⚠️

Assuming MAX handles ties

If two rows share the highest value, INDEX/MATCH and XLOOKUP return only the first one found. On data where ties matter, that silently hides a result.

⚠️

Using MINA or MAXA by accident

They look like harmless variants but count text as zero, so MINA on any column containing a text entry returns 0. Stick to MIN and MAX unless you specifically need the other behaviour.

⚠️

Forgetting to format a date result

MIN and MAX on a date column return the correct date as a serial number like 46023. Format the cell as a date and it displays properly.

Beyond the Spreadsheet

3 Highs and Lows You Hunt For Manually.Flagged Automatically in Updoot.

If you are writing a formula to find the worst number, something should have told you about it already.

🚩
You look for the worst
The task that has slipped furthest
Project Manager
Overdue flags and dependencies surfaced automatically
📦
You look for the lowest
Stock about to run out
Inventory & Asset Tracking
Reorder points and alerts before you hit zero
🏆
You look for the highest
Your best performing rep
Sales CRM
Lead scoring and win/loss ranked for you

Free 14-day trial. No credit card required.

Frequently Asked Questions

What is the formula for max in Excel?

Use =MAX(range), for example =MAX(D2:D20). It returns the largest number in that range, ignoring blanks, text and logical values.

What is the formula for min in Excel?

Use =MIN(range), such as =MIN(D2:D20). The syntax matches MAX exactly and it returns the smallest number.

Why is my MIN returning 0?

There is a real zero somewhere in the range, and zero is a valid value rather than a blank. Use MINIFS with a criteria of greater than 0 to exclude it.

Do MIN and MAX ignore blank cells?

Yes. Blanks, text and logical values are all skipped, so only genuine numbers are considered.

How do I find the name that goes with the highest value?

Wrap MAX in a lookup: =XLOOKUP(MAX(D2:D20),D2:D20,A2:A20) returns the label from column A. On older Excel use INDEX with MATCH instead.

How do I find the second highest value?

Use =LARGE(range,2). LARGE with a 1 is the same as MAX, and SMALL works the same way from the bottom.

How do I find the highest value that meets a condition?

Use =MAXIFS(D2:D20,B2:B20,"Gold"). The value range comes first, followed by pairs of criteria range and criteria. It needs Excel 2019 or Microsoft 365.

What is the difference between MAX and MAXA?

MAX only looks at numbers. MAXA also counts text as 0 and logical values as 0 or 1, which usually gives a different and unhelpful answer.

Can MIN and MAX work on dates?

Yes. Dates are stored as numbers, so MIN gives the earliest and MAX the latest. Format the result cell as a date or it shows a serial number.

How do I cap a value at a maximum?

Use =MIN(D2,1000) to cap at 1000, or =MAX(D2,0) to stop a value going below zero. Nest them to constrain a value between two bounds.

Can I see min and max without a formula?

Yes, but they are off by default. Right-click the status bar, tick Minimum and Maximum, and they appear for any range you select.

Where are MIN and MAX on the ribbon?

Click the arrow beside AutoSum on the Home or Formulas tab and choose Max or Min. They are also under Formulas, More Functions, Statistical.

Ready for data that's already connected?

Every business starts with a spreadsheet. Updoot is where you scale past it, records link themselves automatically.

Start Your Free Trial →