AND doesn't work that way with Array formulae because it ANDs the whole array together in the top left cell, regardless of number of dimensions.

I.e. it checks if "">"" which is FALSE, ANDed with anything it will return FALSE for the top left cell, that result is carried down.

You can use multiplication of truth values to create ANDing that works with ARRAYFORMULA like this:

=ArrayFormula((A1:A>1)*(B1:B>6) = 1)

The OR equivalent would obviously be

=ArrayFormula((A1:A>1)+(B1:B>6) > 0)
Answer from Robin Gertenbach on Stack Overflow
🌐
Ben Collins
benlcollins.com › home › how do array formulas work in google sheets?
How do array formulas work in Google Sheets? Get the lowdown here.
June 20, 2024 - I’m trying to use the ArrayFormula to flatten a table, but I needed to leave the range conditioned to the last row where there’s data, so when I have a new entry, the flattened table is automatically generated.
Discussions

ArrayFormula and "AND" Formula in Google Sheets - Stack Overflow
In Google Sheets, when using ArrayFormula with AND formula, I don't get the results as it should be. A B 6 7 In C1 I put formula as: =and(A1>5,B1>6) then I get True. If in D1 I put formula as: = More on stackoverflow.com
🌐 stackoverflow.com
Can somebody explain array formulas for me in a simple way?
Here is a little write up I did More on reddit.com
🌐 r/excel
8
4
May 3, 2019
What's the difference between ARRAYFORMULA and just dragging down using relative location?
Arrayformulas save on processing time. Instead of checking and calculating 5 separate cells, it only has to check and calculate the one. As an aside, ARRAYFORMULA(SUM(A1:A5, B1:B5)) wouldn't give you the same result. That'd be ARRAYFORMULA(A1:A5+B1:B5). ETA: Unless you've got a very large spreadsheet with hundreds of calculations, the time saved here is rather negligible - especially with trivial calculations like a sum. It's much more powerful when you've got a large spreadsheet with more complex calculations. More on reddit.com
🌐 r/sheets
12
6
March 12, 2023
arrays - How to use an ARRAYFORMULA in Google Sheets that references cells in the same column - Stack Overflow
After getting sick and tired of having to copy formulas back into my sheet anytime I needed to add a row (one of my gripes of Google Sheets where Excel is much better). I've decided to try using More on stackoverflow.com
🌐 stackoverflow.com
🌐
Microsoft Support
support.microsoft.com › en-us › excel › create-an-array-formula-in-excel
Create an array formula in Excel | Microsoft Support
Create array formulas, often called Ctrl Shift Enter or CSE formulas, to perform calculations that generate single or multiple results.
🌐
Microsoft Support
support.microsoft.com › en-us › excel › guidelines-and-examples-of-array-formulas
Guidelines and examples of array formulas | Microsoft Support
An array formula (one that spans multiple cells) can do calculations on rows and columns of cells where you might otherwise need to use several formulas. For example, you can count the number of characters that are contained in a range of cells, sum only numbers that meet certain conditions ...
🌐
Coursera
coursera.org › coursera articles › data › data analytics › how to use the array formula in google sheets
How to Use the Array Formula in Google Sheets | Coursera
November 26, 2025 - To begin the formula shell (i.e., the formula’s starting point), type an equal ( ‘=’ ) symbol in the selected cell, followed by ARRAYFORMULA and open parenthesis ( ‘(’ ) to indicate you will be creating a function.
Top answer
1 of 4
146

AND doesn't work that way with Array formulae because it ANDs the whole array together in the top left cell, regardless of number of dimensions.

I.e. it checks if "">"" which is FALSE, ANDed with anything it will return FALSE for the top left cell, that result is carried down.

You can use multiplication of truth values to create ANDing that works with ARRAYFORMULA like this:

=ArrayFormula((A1:A>1)*(B1:B>6) = 1)

The OR equivalent would obviously be

=ArrayFormula((A1:A>1)+(B1:B>6) > 0)
2 of 4
12
Take this formula for instance:
=ARRAYFORMULA(IF(ISNUMBER(G3:G),IF(AND( G3:G>=7.5,G3:G<=8),"Full Day",IF(AND(G3:G>8,G3:G<24) ,"Full Day+",IF(AND(G3<7.5,G3>=4),"Half Day",IF(G3<4,"Short Leave",)))),))

Since you use the ARRAYFORMULA function you should use * instead of the AND function.

=ARRAYFORMULA(IF(ISNUMBER(A3:A),IF((A3:A>=7.5)*(A3:A<=8),"Full Day",IF((A3:A>8)*(A3:A<24) ,"Full Day+",IF((A3<7.5)*(A3>=4),"Half Day",IF(A3<4,"Short Leave",)))),))

When using the ARRAYFORMULA function you should use * instead of the AND function and + instead of the OR function.


Explanation

I don't recall an official site about this right now. In any case.

Point 1
Within an arrayformula, AND gives a single value. Not an array of TRUE/FALSE.

Point 2
You must also remember that in "math language", TRUE=1 and FALSE=0

Meaning

+----------+--------+
| Formula  | Result |
+----------+--------+
| =TRUE+2  |      3 |
| =FALSE+2 |      2 |
+----------+--------+

As you can see one can interchange between boolean TRUE/FALSE and 1/0 numbers.

Point 3
About the AND function

The AND function returns true if all the provided arguments are logically true and false if any of the provided arguments are logically false.

Putting it all together
In an arrayformula, instead of using AND/OR when making comparisons, we take advantage of the above information.

So, the "multiplication" (A3:A>=7.5)*(A3:A<=8) will return 1 (meaning TRUE) only if both sides return TRUE. All other conditions return 0 (meaning FALSE).
This is the exact behaviour of the AND function and does work in an ARRAYFORMULA.

About the OR function

The OR function returns true if any of the provided arguments are logically true and false if all of the provided arguments are logically false.

The same logic is applied within the arrayformula, when using + ("addition") instead of the OR function.

Find elsewhere
🌐
Coupler.io Blog
blog.coupler.io › home › the complete guide to using arrayformula in google sheets for all
Google Sheets ARRAYFORMULA With Examples | Coupler.io Blog
October 14, 2025 - To use it in Google Sheets, you can either directly type “ARRAYFORMULA” or hit a Ctrl+Shift+Enter Google Sheets shortcut (Cmd + Shift + Enter on a Mac), while your cursor is in the formula bar to make a formula an array formula (Google Sheets will automatically add ARRAYFORMULA to the start of the formula).
🌐
Exceljet
exceljet.net › home › glossary › array formula
Excel Array formula | Exceljet
An array formula is a type of formula that performs an operation on multiple values instead of a single value. The final result of an array formula can be …
Top answer
1 of 3
2

I tried using ARRAYFORMULA using whole columns (e.g. A:A, B:B, etc.) but if it's a formula where I need a result output to each row

you can always freeze it like:

=INDIRECT("A:A")

this way you can add rows anywhere you want (if you of course not add new row above the row that holds the formula - that would be troublesome to fit in A:A into A2:A)


that the INDEX function just does not work with ARRAYFORMULA at all

INDEX is already ARRAYFORMULA type of formula. the analogy being here as: you need a car to get from A to B where INDEX is a blue car with 3 doors and ARRAYFORMULA is a red car with 5 doors - it doesn't matter what color you have, you just need a car


= IF (G2 <> G1, 0, B1 + 1)

while this is direct logic there are several ways how to achieve the same thing. proper usage would require not to use such formulas as ARRAYFORMULA in column G or B to avoid circular dependency errors. for a simple resetting count up try:

=ARRAYFORMULA(COUNTIFS(B1:B7, B1:B7, 
 SEQUENCE(ROWS(B1:B7)),"<="&SEQUENCE(ROWS(B1:B7))))

feel free to change B1:B7 to open range or frozen range...


update:

=INDEX(IF(B2:B="";; COUNTIFS(B2:B; B2:B; 
 SEQUENCE(ROWS(B2:B)); "<="&SEQUENCE(ROWS(B2:B)))-1))

2 of 3
0

You should use the INDEX function with MATCH instead of INDIRECT in your ARRAYFORMULA For example, if your data is in the range A1:A11 , and you want to retrieve the value at row 5 through INDIRECT , you would use: =INDIRECT("A" & 5) If you want to retrieve the value at row 5 through INDEX , you would use: =INDEX(A:A, 5) Now, if you want to use the INDEX function with ARRAYFORMULA , you will need to use the MATCH function to find the row number of the value you want, since INDEX only takes a row number as its second argument. For example, if you want to retrieve the value at row 5 through ARRAYFORMULA and INDEX/MATCH , you would use: =ARRAYFORMULA(INDEX(A:A, MATCH(5, ROW(A:A)))) This formula will return the value in A5

Note: In your example, you're trying to match $G2 with $G1:$G1 . If you want to match $G2 with $G1:$G3 , you would use: =ARRAYFORMULA(INDEX(A:A, MATCH($G2, $G1:$G3))) This formula will return the value from A1 , A2 , or A3 depending on the value of $G2

🌐
Reddit
reddit.com › r/sheets › how to do array formula?
r/sheets on Reddit: How to do array formula?
June 30, 2023 -

I have a sheet listing names with categories. Every time I start a new category, I need the numbering to start from one. I have a code that works well, but I have to copy paste the code every time I add a new row. I'm quite new to google sheets and just found out about ARRAYFORMULA.

This is my current formula:

=IF(B35 = B34, C34+1, "")

  • Column B has the category names (they are always in order...like same category goes in adjacent rows)

  • Column C has the numbering.

  • The formula pasted here is for cell C35.

I already tried with this, but it gives an error.

=ArrayFormula(IF(B35:B = B34:B, C34:C+1, ""))

How do I convert this into ARRAYFORMULA?

Any help would be appreciated.

🌐
Excel Insider
excelinsider.com › home › our blog › google sheets functions › 13 examples with arrayformula in google sheets
13 Examples with ARRAYFORMULA in Google Sheets - Excel Insider
October 8, 2025 - The ARRAYFORMULA function is an array function that expands the output into different columns and rows dynamically.
🌐
Lark
larksuite.com › hc › en-US › articles › 360048488522-arrayformula-function-for-sheets
ARRAYFORMULA function for Sheets
October 8, 2022 - I. Intro The ARRAYFORMULA function is used to display the values returned by an array formula into a range of cells instead of one cell. ARRAYFORMULA
🌐
Spreadsheet Class
spreadsheetclass.com › home › google sheets formulas › arrayformula & 5 ways to apply a formula to an entire column in google sheets
ARRAYFORMULA & 5 ways to apply a formula to an entire column in Google Sheets
April 23, 2026 - The formula above will apply the functionality of the formula to the entire column, by using a single formula entered into a cell. This is exactly what the ARRAYFORMULA function does, and why it’s so amazing.
🌐
Layer
golayer.io › home › how to use google sheets arrayformula (+ examples)
How to Use Google Sheets ARRAYFORMULA (+ Examples) | Layer Blog
September 23, 2024 - For this example, I have a table listing multiple transactions for three different products. Instead of calculating the total for each product, I can use SUMIF to calculate the total per product and ARRAYFORMULA to return an array with the three totals.
🌐
Glide Community
community.glideapps.com › ask for help
Tutorial: Arrayformula in Google Sheets, good practices & how to overcome Arrayformula restrictions with scripts - Ask for Help - Glide Community
May 25, 2020 - Hi, Today I will show you the script that can make copying formulas down work, when it does not work with arrayformula. But first, let’s have some introductions about arrayformula, for those who has not used this before in Google Sheets, some equivalents in Glide and some good practices while ...
🌐
Superjoin
superjoin.ai › home › blog › how to use arrayformula in google sheets
How to Use ArrayFormula in Google Sheets | Superjoin
August 27, 2024 - Data management in spreadsheets can often feel like navigating a maze, especially when dealing with repetitive tasks. Google Sheets, however, offers a hidden gem that can make your workflow far more efficient: the ArrayFormula function, which enables you to perform calculations over a range of cells at once, rather than typing formulas for each individual cell.
🌐
Digital-transformation
digital-transformation.media › en › g-suite › google-sheet-arrayformula
Google Sheets ARRAYFORMULA : How to use ARRAYFORMULA?
October 9, 2019 - Google Sheets ARRAYFORMULA is the simplified one time formula, replacing the repeated formula. For an example, if you have a calculation A*B+A*C+A*D+A*E, by using ARRAYFORMULA in Google Sheets, you can simplify it to A(B+C+D+E).