Returns the largest (maximum) value from a set of numbers. MAX finds the highest numeric value in a range or list of arguments. Essential for identifying peak values, finding maximums, data analysis, performance tracking, and statistical calculations.
Master the fundamentals of Excel MAX function
The MAX function returns the largest (maximum) value from a set of numbers. MAX evaluates all numeric values in the provided arguments and returns the highest one. MAX ignores text values, logical values (TRUE/FALSE), and empty cells. It is one of the fundamental statistical functions for finding extreme values. Essential for identifying peak values, finding maximums in data analysis, performance tracking, quality control, and statistical calculations.
Finds highest numeric value
Only considers numeric values
Accepts up to 255 arguments
MAX and MIN are opposites
Function-specific parameters
Function-specific return type
Find peak values
Find maximum performance
Find maximum measurements
Find upper bound or range
Exact matching required
Returns numeric position
Handles missing text gracefully
=MAX(number1, number2)First number, cell reference, or range.
Additional numbers, cell references, or ranges (up to 255 arguments).
The largest (maximum) value
Description: Returns the largest value from a set of numbers
Find maximum value
Returns 50, the largest value in the set. MAX finds the highest number from all arguments.
Use MAX function in VBA
' Basic MAX in VBA
Range("C1").Value = Application.WorksheetFunction.Max(Range("A1:A10"))
' Returns: Maximum value
' Find maximum
Sub FindMaximum()
Dim maxValue As Double
maxValue = Application.WorksheetFunction.Max(Range("A1:A10"))
Range("B1").Value = maxValue
End Sub
' Find maximum across multiple ranges
Sub MaxMultipleRanges()
Dim maxValue As Double
maxValue = Application.WorksheetFunction.Max( _
Range("A1:A10"), _
Range("B1:B10"), _
Range("C1:C10"))
Range("D1").Value = maxValue
End Sub
' Find maximum with condition (using array formula concept)
Sub MaxWithCondition()
Dim dataRange As Range
Dim criteriaRange As Range
Dim maxValue As Variant
Set dataRange = Range("A1:A10")
Set criteriaRange = Range("B1:B10")
' Use MAXIFS equivalent logic
maxValue = Application.WorksheetFunction.MaxIfs(dataRange, criteriaRange, ">50")
Range("C1").Value = maxValue
End Sub
' Compare MAX with LARGE
Sub CompareMaxLarge()
Dim maxValue As Double
Dim largeValue As Double
maxValue = Application.WorksheetFunction.Max(Range("A1:A10"))
largeValue = Application.WorksheetFunction.Large(Range("A1:A10"), 1)
Range("B1").Value = "MAX: " & maxValue
Range("B2").Value = "LARGE(1): " & largeValue
' Should be equal
End SubFind peak values in analysis
Find maximum performance metrics
Find maximum measurements
Find upper bound or range
MAX returns 0 when negative values exist
Check: MAX(-10, -5, 0) = 0 (0 is largest)Solution: MAX returns 0 only if 0 is the largest value, or if all values are negative and 0 is present. Check if you actually have larger values. MAX finds the largest value, which might be negative.
MAX seems to ignore negative numbers
MAX includes negatives: MAX(-10, -5) = -5Solution: This is not correct. MAX includes negative values. MAX(-10, -5, 5) = 5. MAX(-10, -5) = -5 (least negative). MAX always finds the largest value, which can be negative.
Text that looks like numbers not included
Use VALUE() to convert text to numbersSolution: MAX only considers actual numeric values. Text that looks like numbers (e.g., "100") is ignored. Convert text to numbers first: VALUE("100") or fix data format.
Need maximum with conditions
Use MAXIFS for conditional maximumSolution: MAX finds overall maximum. For conditional maximum, use MAXIFS: MAXIFS(data_range, criteria_range, criteria). MAXIFS finds maximum value meeting specific criteria.