# How to find the minimum value excluding zeros in Excel

Use MINIFS with ">0" on the same range: `=MINIFS(B2:B7,B2:B7,">0")`.

**Excel:** `=MINIFS(B2:B7,B2:B7,">0")` (Excel 2019 and later, including Microsoft 365)

**Google Sheets:** the same formula works.

## Example

Sample data (row 1 is the header):

| A | B | C | D |
| --- | --- | --- | --- |
| Store | Price |  | Lowest price |
| Store A | 24.99 |  |  |
| Store B | 0 |  |  |
| Store C | 22.5 |  |  |
| Store D | 26.75 |  |  |
| Store E | 0 |  |  |
| Store F | 23.4 |  |  |

Formula in E1: `=MINIFS(B2:B7,B2:B7,">0")`

Result: $22.50

## How it works

MIN would return 0 from the stores that don't stock the item. MINIFS with the condition `">0"` on the same range looks only at real prices and returns the lowest: $22.50.

## Other ways

- `=SMALL(B2:B7,COUNTIF(B2:B7,0)+1)`: Skips past the zeros by rank: with two zeros, the 3rd smallest value is the lowest real price. Works in every version.
- `=MIN(B2:B7)`: The plain minimum. (Returns one of the zeros: 0.)

## Common mistakes

- `">0"` also skips negative numbers. To skip only zeros, use `"<>0"`.
- Blank cells are already ignored by MIN; the zeros are the problem. Leaving unknown prices blank avoids it.

## Questions

**How do I find the maximum excluding zeros?**

MAX already ignores zeros unless every value is 0 or negative. For negatives, use `=MAXIFS(B2:B7,B2:B7,"<>0")`.

**How do I return the store with the lowest price?**

Use `=XLOOKUP(E1,B2:B7,A2:A7)`.

Every formula and result on this page was checked by running it in the Spreadsheet Practice formula engine on 2026-10-30.

Source: https://spreadsheetpractice.com/formulas/minimum-excluding-zeros
