How to Use the ISTEXT Function in Google Sheets (Easy)

By

Sometimes you’re using Google Sheets not to collect your own information, but to collect information from others. At that point, you need something called validation.

Validation ensures that the data that’s entered is correct. For instance, if you’re filling out a survey, and you need to make sure that the names are entered properly.

Validation can be very important, because if you don’t validate data properly, it can be imported correctly, too.

Let’s take a look at the Google Sheets ISTEXT function and how it works to tell you whether a cell is text or not.

What is the ISTEXT Function?

ISTEXT is a very simple function. With ISTEXT, you’re given a “TRUE” response if the cell given is text and a “FALSE” response if the cell given is not text.

It’s part of a suite of functions that looks at the data within the cell and determines what type of data that is — and whether it’s the correct type of data.

ISTEXT will only ever return TRUE or FALSE, so it can also be used in more complicated algorithms such as IF.

How Do You Use ISTEXT in Google Sheets?

using istext google sheets

In the above sheet, we have created a sheet for Contact Information. Here, people are able to enter in “Name,” “Email Address,” and “Phone Number.” We then have a column that uses ISTEXT to validate it.

istext function

Here we can see how ISTEXT is used:

=ISTEXT(B2)

B2 is the value that we’re testing. In the first example, we can see that John Doe is text (and correct), john@doe.com is text (and correct), and the phone number 5551234589 is NOT text (and correct).

In the second example, we see that Jane has entered her data incorrectly. She has put in her phone number with hyphens, so it is no longer just a number. If we were importing this into a database that required that to be a number, there would be an error.

Related: How to Convert Text to Numbers in Google Sheets

Using ISTEXT with the IF Function

How are we validating whether it’s “correct” or “incorrect”? In the case of the email address, it has to be ISTEXT (TRUE). But in the case of the number, it has to be ISTEXT (FALSE).

We are using IF statements, which are a little more advanced.

Using ISTEXT with the IF Function

Because ISTEXT returns “true” or “false,” we can use an IF function with it. The above function basically says “If ISTEXT is true, you type ‘This entry is correct.’ If ISTEXT is false, you type ‘This entry is wrong’.”

That makes it clearer to the user that they’ve entered the wrong content. And that can help when collecting user information.

Taking the Next Steps

Along with ISTEXT, there’s also ISNUMBER.

isnumber

Here, we used ISNUMBER on the phone number and received “FALSE” rather than “TRUE.” If we wanted to be a little more consistent, we would use ISTEXT for things that are supposed to be TEXT and we would use ISNUMBER for things that are supposed to be NUMBER.

We can also do things like ISDATE, ISURL, ISEVEN, or ISODD. All these are text validation sequences that are intended to make it easier for you to figure out whether the right content has been entered into a spreadsheet.

We hope this quick tutorial has helped you figure out how to use the ISTEXT function in Google Sheets!

Related: The Ultimate Guide to Conditional Formatting in Google Sheets

Popular Posts

Access All

Free Templates

Enjoy our custom-made Google Sheets templates for free via email access