fgFormula Gym
Interactive lesson · Excel & Google Sheets

The Excel AND function, explained interactively.

Last updated: April 2026

AND combines up to 255 logical tests into a single TRUE/FALSE result: it returns TRUE only when every argument is TRUE. A single FALSE anywhere in the chain collapses the whole thing to FALSE. It’s the universal gate for approval-style conditions — IF(AND(score≥60, age≥18), "Pass", "Fail") — and the natural partner to IF, OR, and NOT.

01 · See it work

How to use AND

Pass two or more logical tests — AND returns TRUE only when every one is TRUE. Open the playground to flip thresholds and watch the result collapse the moment any test fails.

  1. Type =AND( and supply the first logical test — a comparison like B2>=60, a cell reference holding TRUE or FALSE, or any formula returning a boolean.
  2. Add a comma and the next logical test. Repeat for each condition you want to combine — AND accepts up to 255 arguments.
  3. Close the parenthesis. AND walks the arguments and returns TRUE only when every one evaluates to TRUE; any single FALSE returns FALSE immediately.
  4. Wrap with IF to branch on the result: =IF(AND(B2>=60, C2>=18), "Eligible", "Denied").
FUNCTIONAND
Returns TRUE only if every argument is TRUE. The first FALSE short-circuits the whole result. Accepts 1 to 255 logical arguments.
ARG 1logical1
The first logical test. Usually a comparison like B2>=60 that evaluates to TRUE or FALSE. A cell reference, a literal, or any formula returning boolean is accepted.
ARG 2[logical2]
Optional. Additional tests — up to 255 total. If any one returns FALSE the whole AND is FALSE, so ordering cheap tests first speeds evaluation on large ranges.
D2
fx
=AND(B2>=60, C2>=18)
ABC
1NameScoreAge
2Ava8520
3
4AND resultTRUE
B2>=60 TRUE · C2>=18 TRUE → AND = TRUE. Every condition passed.
02 · Syntax, argument by argument

AND syntax and arguments

One required logical test plus up to 254 additional. See Microsoft’s official AND reference.

=AND(logical1, [logical2], …)
logical1
Required. The first logical test — almost always a comparison expression like B2>=60, A2="YES", or a cell/formula returning TRUE/FALSE. Numbers are accepted: zero is treated as FALSE, any non-zero as TRUE. Empty cells are treated as FALSE without error.
[logical2], [logical3], …
Optional. Up to 254 additional tests, for a total of 255 arguments.
  • AND evaluates every argument; it does not short-circuit the way most programming languages do. Expensive formulas inside later arguments are still computed even when an earlier one is FALSE.
  • Passing text that isn’t literal "TRUE" or "FALSE" returns #VALUE!.
  • Passing a range collapses it to a single boolean — AND(A2:A10) is TRUE only if every cell in A2:A10 is truthy. Empty cells still count as FALSE inside a range.
03 · In the wild

AND examples

Three patterns that cover most real-world AND usage.

Example 1: AND with two numeric conditions

The classic pass/fail gate. Each row gets a plain TRUE or FALSE based on whether both thresholds are met. Useful as a helper column before layering IF or COUNTIFS on top.

=AND(B2>=60, C2>=18)

Returns TRUE only when the score is at least 60 and the age is at least 18. Drop either condition and AND collapses to FALSE — a single failing test rules out the whole row.

Example 2: IF(AND(…)) — approval gate

The canonical approval-decision pattern. IF branches on the AND result, producing a human-readable label instead of a bare boolean — ready for reports or dashboard output.

=IF(AND(B2>=40000, C2>=700), "Approved", "Declined")

Income must reach 40 000 and credit score must reach 700 for approval. Either threshold missed declines the application — same logic as underwriting criteria in real lending workflows.

Example 3: AND with three or more conditions

AND scales naturally. Three, five, ten conditions all work the same way — every one must be TRUE. The common complaint about long ANDs is readability, not correctness.

=AND(B2="YES", C2="YES", D2>0)

Returns TRUE only when stock is in, product is active, AND price is positive. Used as a "listable product" flag before catalog sync. Extend with additional conditions by adding commas.

04 · Errata

Common AND errors and fixes

One noisy error, two silent pitfalls worth knowing.

AND returns #VALUE! on non-logical text

Cause: an argument is text that can’t be interpreted as a boolean — a free-form string like "hello" or an entry that should have been YES/NO converted to TRUE/FALSE. Literal "TRUE" and "FALSE" strings are fine; anything else errors.

To fix: either wrap the text in a comparison (A2="YES") or coerce early with =ISNUMBER(A2)-style audits. If a cell sometimes holds TRUE/FALSE and sometimes blank, empty cells count as FALSE and do not error — only unrecognised text does.

AND of an empty range is TRUE — not what you expect

Cause: an empty range or a range of all blanks makes =AND(A2:A10) return TRUE, not FALSE — vacuous truth over zero non-blank arguments. This can let empty data masquerade as fully-valid in a dashboard.

Add a count guard upstream: =IF(COUNTA(A2:A10)=0, FALSE, AND(A2:A10)). Or use explicit arguments instead of a range, where the intent stays in the formula text.

AND doesn’t short-circuit — costly later arguments still run

Cause: unlike && in most programming languages, AND evaluates every argument even after it finds a FALSE. If later conditions call slow formulas (VLOOKUP across a big range, SUMPRODUCT over thousands of rows), they still run — AND just ignores their truth value.

Put the cheapest checks first for readability, not performance. For real short-circuit semantics, nest IF around AND: =IF(B2>=60, AND(C2>=18, VLOOKUP(…)), FALSE). The outer IF skips the AND branch entirely when the cheap test fails.

05 · Kindred functions

AND vs OR, NOT, and IF logic

AND is one of four boolean building blocks. Knowing which to reach for keeps formulas short and readable.

FunctionReturns TRUE when…Typical useShort-circuit?
ANDEvery argument is TRUEApproval gates, compound validation checksNo — evaluates all args
ORAny argument is TRUEMatch-one-of-many categories, whitelistsNo
NOTThe single argument is FALSEInverting a condition, excluding a valueN/A — single argument
IF(returns one of two branches)Branching on an AND/OR result to produce labels, values, or further formulasYes — only the taken branch runs
Boolean multiplication (A=1)*(B=2)Both comparisons return TRUE (1×1 = 1)Array-aware conditional sums inside SUMPRODUCTNo — coerces whole arrays

Rule of thumb: reach for AND inside IF for scalar branching, for OR when any of several options should trigger, and for boolean multiplication when conditions need to apply across an array. AND collapses an array to a single boolean, so it doesn’t replace multiplication in SUMPRODUCT-style contexts.

06 · Marginalia

AND frequently asked questions

6.01What does AND do in Excel?

AND takes up to 255 logical arguments and returns TRUE only if every one of them is TRUE. If any single argument returns FALSE, AND returns FALSE. It’s the workhorse of compound conditions — the standard pattern is IF(AND(condition1, condition2), "yes", "no").

6.02How do I combine AND with IF in Excel?

Wrap AND inside IF as the logical_test: =IF(AND(B2>=60, C2>=18), "Eligible", "Not eligible"). AND collapses multiple conditions into one boolean, which IF then branches on. This is the canonical approval-gate pattern — only passes when every requirement is met.

6.03Why does AND return #VALUE!?

AND returns #VALUE! when an argument is text that can’t be interpreted as a boolean — for example, =AND("hello", TRUE). The text must be "TRUE" or "FALSE" (case-insensitive), a number, a comparison, or a cell that evaluates to one of these. Empty cells are treated as FALSE, not as errors.

6.04How many conditions can AND take?

Up to 255 logical arguments. In practice, passing more than three or four becomes hard to read — prefer breaking conditions into helper cells or nested AND/OR trees. If you need many conditions combined with OR behavior, use OR; for mixed AND/OR logic, nest them: =AND(OR(A=1,A=2), B>0).

6.05What’s the difference between AND and multiplying booleans?

AND returns a single TRUE/FALSE. Multiplying booleans — (A=1)*(B=2) — also returns 1 (truthy) or 0 (falsy) and is array-aware. For scalar logic inside IF, AND is clearer. For array-aware conditional sums (e.g., inside SUMPRODUCT), multiplication is the standard idiom because AND collapses an array down to a single boolean.

6.06Does AND work the same in Google Sheets?

Yes. AND has an identical signature and behavior in Google Sheets — accepts up to 255 arguments and returns TRUE only when all are TRUE. Empty-cell handling, error propagation, and nested IF patterns all match. Formulas written in either product port directly to the other.

Microsoft Excel is a registered trademark of Microsoft Corporation. Google Sheets is a trademark of Google LLC. Formula Gym is not affiliated with, endorsed by, or sponsored by either company.