The ISTEXT function in Google Sheets is used when you need to determine whether the value of a cell is a text value.
With this function, the value returned is TRUE if the cell contains text and FALSE if it does not.
The rules for using the ISTEXT
function in Google Sheets are as follows:
- The function requires the value to be determined as a text value.
- The function then outputs a boolean result depending on whether the argument provided is a text value or not.
- Text values do not include numbers, dates, and error values.
Let’s begin with a quick use case!
When dealing with user input, it’s not always the case that you’ll be dealing with uniform data. For example, if I were to set up a list of books, it’s possible that an entry for George Orwell’s “1984” may be treated as numeric, rather than as text. It might be useful to detect such instances in your worksheet.
With the ISTEXT
function it becomes an easy task to find out what values in your worksheets are not considered text values. We can use the ISTEXT
function to flag outlier data, filter out unusable values, and clean your dataset as well.
Let’s learn how to write the ISTEXT
function in Google Sheets and later test out the function with actual date values.
The Anatomy of the ISTEXT Function
So the syntax (the way we write) of the ISTEXT
function is as follows:
=ISTEXT(value)
Let’s dissect this thing and understand what each of these terms means:
- = the equal sign is how we start any function in Google Sheets.
- ISTEXT() is our
ISTEXT
function. It Checks whether a given value is text. - value is the value that will be verified as text. It may be the value itself or a cell reference to a cell containing the value.
A Real Example of Using ISTEXT Function
Let’s look at a real example of the ISTEXT
function being used in a Google Sheets spreadsheet.
In the example below, we have various types of input that can be encountered in a Google Sheets worksheet. Column B shows us which value is text, and which is not. Numeric, Boolean, and date values will output FALSE.
Notice that cell A$ may look numeric, but it is actually written as text. Similarly, cell A8 looks like a date, but Google Sheets does not recognize it as such since it is incomplete.
We just need to use the following formula to return the values found in Column B.
=ISTEXT(A2)
You can make your own copy of the spreadsheet above using the link I have attached below.
We can also use the ISTEXT
function to handle logical tests. For example, in the example below, we used ISTEXT
to determine whether to return the phrase in Column C. Because of the IF
conditional statement, the phrases will not show if the values in Column A are non-textual. Since cell A4 is an empty cell, ISTEXT(A4)
returns FALSE, prompting the formula in C4 to return an empty string instead.
If you’re prepared to try out the ISTEXT
function in Google Sheets on your own, follow the step-by-step guide in the next section!
How to Use ISTEXT Function in Google Sheets
- To start using the
ISTEXT
function, select the cell we will be placing our function’s output. In this example, we’ll start with cell C2.
- Next, we just simply type the equal sign ‘=‘ to begin the function, followed by ‘ISTEXT(‘.
- As seen in the screenshot below, a tooltip box may appear with information on the
ISTEXT
function. We can click on the arrow on the top-right-hand corner of the box to minimize it if necessary.
- The next step is to type in our argument to verify as a text value.
Next, simply hit Enter to let Google Sheets evaluate the function.
- Lastly, we can drag down the formula in cell C2 to fill the rest of Column C with our
ISTEXT
function results.
Frequently Asked Questions (FAQ)
- Why does my formula return TRUE even if the value is numeric?
It’s possible that the cell being referenced is written in quotations like a string, as in=”13”
. It’s also possible that your column or cell range is formatted as Plain Text. - What happens if the formula tries to check an empty cell?
TheISTEXT
function treats empty cells as non-textual. Providing a reference to an empty cell will result in a FALSE result.
That’s all you need to know to start using the ISTEXT
function in Google Sheets. This guide shows how easy it is to return whether a certain cell contains a text value.
You can now use the ISTEXT
functions in Google Sheets together with the various other Google Sheets formulas available to create great worksheets that work for you. In cases where you would want to know whether a function is non-textual, you may want to use the ISNONTEXT
function instead.
Make sure to subscribe to our newsletter to be the first to know about the latest Google Sheets tutorials from us.