HomeGoogle DocsSpreadsheetUsage of Google Sheets CELL Function and Examples

Usage of Google Sheets CELL Function and Examples

Published on

Google Sheets CELL function is related to gathering limited information about any Cell in a Spreadsheet. But don’t undermine this function as it can be a useful tool on certain occasions. In this new Google Sheets tutorial, you can learn what are those information Google Sheets CELL function can return.

To use CELL Function in Google Sheets, first, you should know about information type called “info_type”.

How to USE CELL Function in Google Sheets

I’ve already mentioned about the purpose of CELL function above. Now see the syntax.

CELL(info_type, reference)

In this syntax, “reference” is the cell reference of which you want to get the information. Now see detailed information about “info_type” after one example.

=CELL("COL",G2)

This Google Sheets CELL formula would return the result 7 which is the Column Number of G. Here “COL” is the “info_type” to return Column number. You can see below all the available info types in CELL function.

Google Sheets CELL Function “Info Types” and Examples

I’ve detailed available info types in different sections like Part I, Part II etc. So I hope, you can easily grasp the usage of this formula.

Google Sheets Cell Function Info Type Part I:

=CELL("address",A1)

Result: $A$1

Note: returns an absolute cell reference (it’s all about placing the dollar symbol) in text form.

=CELL("col",A1)

Result: 1

Note: Returns the column number of A1.

=CELL("row",A1)

Result: 1

Note: Returns the row number of A1.

Google Sheets Cell Function Info Type Part II:

=CELL("contents",A1)

Note: Returns the cell content in A1 as it is. If cell A1 contains the value 10, the formula would return the value 10. That means the formula is equal to =A1.

Google Sheets Cell Function Info Type Part III:

=CELL("type",A1)

Note: This formula returns the letter B for Blank, L for Label or Plain Text and V for Value

Example of Cell function in Google Sheets When info_type is “type”

Suppose the cell value in A1 is the text “Info Inspired”. The function would return the letter “L”. This you can use in an IF logical test as below.

Google Sheets CELL Formula in Logical Test

=if(cell("type",A1)="V",A1*2)

This IF formula would check the cell A1 and if A1 contains a number, it would multiply the number with 2. The following formula using ISNUMBER is equal to the above.

=if(ISNUMBER(A1),A1*2)

In both cases, if the value in A1 is text, the formula would return FALSE. But I suggest you use the second formula as you can use this in an array hassle free. When you use the first formula with an array, it would return “#VALUE!” error if any cell contains the text value.

Cell formula in IF logical test in Google Sheets

Google Sheets Cell Function Info Type Part IV:

Formula: CELL("prefix",A1)

Here you can see that I’ve used “prefix” which is another CELL formula info_type. It merely returns the horizontal cell alignment info. It returns a single quote for left-aligned text, double quotes for right aligned text, carat for centered text and empty for everything else.

get text alignment info in Google Sheets

Google Sheets Cell Function Info Type Part V:

Formula: CELL("width",A1)

By using width information type in Cell formula, you can find how many characters can perfectly fit into a cell.

Conclusion

The above are the currently available info_type in Google Sheets CELL function. You can see that sometimes the results wrongly appear when using this function. If any of the above info types may return blank or wrong output, you can double click on the cell where you applied the formula to see the actual cell info. That’s all. Enjoy.

Prashanth KV
Prashanth KVhttps://infoinspired.com/about-me/
Introducing Prashanth KV: Your Trusted Google Sheets and Excel Guide Prashanth KV brings a wealth of experience in Google Sheets and Excel, cultivated through years of work with multinational corporations in Mumbai and Dubai. As a recognized Google Product Expert in Docs Editors, Prashanth shares his expertise through insightful blogging since 2012. Explore his blog for practical tips and guidance on maximizing your spreadsheet skills.

Creating a Running Balance with Dynamic Array Formulas in Excel

For calculating a running balance, we can utilize the SCAN function, which is a...

Comparing the FILTER Function in Excel and Google Sheets

I believe comparing the differences in how the FILTER functions work in Excel and...

Quartile IF in Google Sheets

To calculate quartiles based on conditions, referred to as "Quartile IF," we will use...

Drop Rows and Columns by Index Numbers in Google Sheets

With the help of two simple custom formulas, we can drop rows and columns...

More like this

Quartile IF in Google Sheets

To calculate quartiles based on conditions, referred to as "Quartile IF," we will use...

Drop Rows and Columns by Index Numbers in Google Sheets

With the help of two simple custom formulas, we can drop rows and columns...

Reference a Column by Field Label in Google Sheets QUERY

Here we'll explore the two best methods for referencing a column by its field...

LEAVE A REPLY

Please enter your comment!
Please enter your name here