HomeGoogle DocsSpreadsheetHow to Use the ISLOGICAL Function in Google Sheets

How to Use the ISLOGICAL Function in Google Sheets

Published on

The ISLOGICAL function in Google Sheets is an info type function. That means you can use it to gather information about value in a cell.

The ISLOGICAL function is useful to identify the Boolean values that denoted by TRUE or FALSE in Google Spreadsheets.

A cell may contain either of the above Boolean values in three ways – as an output of Logical test, by inserting tick boxes, or by manually entering.

Tick Boxes in Google Sheets Placing the Boolean Values in Cells

The tick boxes only contain the Boolean values - example

The Logical Formula That Returns the Boolean Values in Cells

Here is one example with the Logical AND function which returns the TRUE or FALSE values.

Logical AND returns Boolean Values only - Example

There are other logical functions like IF, OR, XOR etc. that can return similar values. You can find that functions under the heading “Logical” in my Functions Guide.

Just type TRUE or FALSE values in a cell/cells. Google Sheets will treat that as Boolean values. Back to the use of the ISLOGICAL Function in Google Sheets.

Purpose:

The one and only purpose of the function ISLOGICAL in Google Docs Sheets is to check whether a value is TRUE or FALSE.

Example to the Use of the ISLOGICAL Function in Google Sheets

In the below examples, the ISLOGICAL formula tests the values in the column C.

Example to ISLOGICAL Function in Google Sheets

The interesting fact is that the ISLOGICAL function tests the presence of Boolean values and also returning the Boolean Values as the output.

To convert that output to numerical 1 or 0, change the formula as below.

The formula in cell E2:

=--islogical(C2)

The Use of ISLOGICAL Function in an Array in Google Sheets

This info type function can be useful to test a set of values using ArrayFormula. If you want to get the info of the values in C2:C12, you can use the formula as below.

=ArrayFormula(islogical(C2:C12))

Practical Use of Google Sheets ISLOGICAL Function

Just learning an info type function is not enough. You must know where you can make use it in your data manipulation.

I am going to use this function in two entirely different scenarios.

  1. As a worksheet formula.
  2. As a custom formula rule in conditional formatting.

Example to the Use of ISLOGICAL with FILTER Function

Problem: Filter only those rows that contain a tick box in column B.

=filter(A2:B13,ISLOGICAL(B2:B13))
Filter formula criteria using ISLOGICAL Function

Highlight Boolean Values Using ISLOGICAL in Google Sheets

To avoid screenshot I am going to use the sample data used in the above example. But this time includes not only column A and B but also the columns D and E.

Steps:

  1. Select the range A1:E13.
  2. From the menu Format, select “Conditional formatting”
  3. Select “Format rules” as “Custom formula is”
  4. Enter the following ISLOGICAL formula in the provided field.
=islogical(A1)

This will conditional format all the cells that contain the TRUE or FALSE values or checkboxes.

Additional Reading:

  1. How to Convert TRUE/FALSE to Checkboxes in Google Sheets.
  2. 10 Best Tick Box Tips and Tricks in Google Sheets.
Prashanth KV
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.

Get the First or Last Row/Column in a New Google Sheets Table

If you've recently started using the new Google Sheets TABLE functionality, you may find...

UNIQUE Function in Visible Rows in Google Sheets

The UNIQUE function doesn't inherently include only visible rows when it returns values, discarding...

Customizing Alternating Colors of a Table in Google Sheets

Google Sheets' new table feature offers limited options for customizing colors. While you can...

Structured Table References in Formulas in Google Sheets

When you create a Google Sheets table by inserting custom tables or converting a...

More like this

Get the First or Last Row/Column in a New Google Sheets Table

If you've recently started using the new Google Sheets TABLE functionality, you may find...

UNIQUE Function in Visible Rows in Google Sheets

The UNIQUE function doesn't inherently include only visible rows when it returns values, discarding...

Customizing Alternating Colors of a Table in Google Sheets

Google Sheets' new table feature offers limited options for customizing colors. While you can...

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.