# Google Sheets SEARCHB Function: Syntax, Examples & Tips

- URL: https://betteranalyst.com/google-sheets/searchb-function
- Author: Better Analyst

Formula Bot is now Better Analyst—same account, more powerful analysis.Formula Bot is now Better Analyst—same account and workflows, with more powerful analysis, dashboards, and automation.

[Learn what changed](https://betteranalyst.com/formula-bot-is-now-better-analyst)

The SEARCHB function locates a substring within a text string, returning the position of the first character of the substring.

```
SEARCHB(search_for, text_to_search, [starting_at])
```

Generate FormulaExplain Formula

One free generation or explanation per browser, shared across Excel and Google Sheets. Account usage limits apply afterward.

Describe the SEARCHB you need in plain EnglishGenerate Formula

## Parameters

**`search_for`**:\
The text or character that you want to find within the `text_to_search`. This can be a string or a cell reference containing the string.

**`text_to_search`**:\
The text or cell reference in which you want to search for the `search_for` text.

**`starting_at`**:\
(Optional) The position in the `text_to_search` from which to start the search. If omitted, the search begins at the first character.

## What is a SEARCHB Google Sheets Formula?

The *SEARCHB* function in Google Sheets is a useful tool for finding the position of a substring within a string. It is particularly beneficial when dealing with text in different languages, as it allows for the use of byte-based character counting. This means that it can accurately locate characters in languages that use multi-byte character sets, such as Chinese or Japanese.

In simpler terms, SEARCHB helps you identify where a specific piece of text appears within a larger text string, making it easier to manipulate and analyze text data.

## A Practical Example

Imagine you have a list of product descriptions in a Google Sheets document, and you want to find out if a specific keyword appears in each description.

### Product Descriptions Table:

| ProductID | Description |
| - | - |
| 1 | High-quality Widget A |
| 2 | Affordable Widget B |
| 3 | Premium Widget C with features |

You want to check if the word "Widget" appears in each description.

## SEARCHB Formula

To achieve this, you would use the SEARCHB function as follows:

```
=SEARCHB("Widget", B2)
```

In this formula:

- `"Widget"` is the substring you are searching for.
- `B2` is the cell containing the description you want to search within.

## Result of the Formula

When you apply the SEARCHB formula to the Product Descriptions Table, the output would look like this:

| ProductID | Description | Position |
| - | - | - |
| 1 | High-quality Widget A | 15 |
| 2 | Affordable Widget B | 12 |
| 3 | Premium Widget C with features | 9 |

The "Position" column indicates where the word "Widget" starts in each description. If the substring is not found, the formula will return an error.

## Why Use SEARCHB?

SEARCHB is beneficial because it allows for precise text searching in Google Sheets, especially when working with languages that use multi-byte characters. It simplifies the process of locating substrings, making it easier to analyze and manipulate text data. Additionally, it can be combined with other functions to create more complex formulas for data analysis.

## Key Takeaways:

- **SEARCHB**: A Google Sheets function that finds the position of a substring within a string using byte-based character counting.
- **Multi-byte Support**: Ideal for searching text in languages that use multi-byte character sets.
- **Error Handling**: Returns an error if the substring is not found, which can be managed with additional functions.
- **Common Use Cases**: Useful for text analysis, data cleaning, and any scenario where substring searching is necessary.

SEARCHB is an essential function for anyone working with text data in Google Sheets, providing a powerful way to enhance text analysis and reporting capabilities.

Happy spreadsheeting!

## Example use case

You have a list of product descriptions in Column A and want to find specific keywords. Use SEARCHB to identify rows containing "organic" or "gluten-free," allowing for quick filtering of products that meet dietary preferences.

## Need more help with Google Sheets formulas?

Sign up for Better Analyst and get unlimited AI-powered formula generation, explanations, and advanced data analysis.

[Create Free Account](https://betteranalyst.com/signup)[Try Formula Generator](https://betteranalyst.com/excel-ai)

## Google Sheets how-to guides

- [How To Remove Duplicates In Google Sheets](https://betteranalyst.com/google-sheets/how-to-remove-duplicates-in-google-sheets)
- [How To Separate Names In Google Sheets](https://betteranalyst.com/google-sheets/how-to-separate-names-in-google-sheets)
- [How To Sort In Google Sheets](https://betteranalyst.com/google-sheets/how-to-sort-in-google-sheets)
- [How To Split Cells In Google Sheets](https://betteranalyst.com/google-sheets/how-to-split-cells-in-google-sheets)
- [How To Strikethrough In Google Sheets](https://betteranalyst.com/google-sheets/how-to-strikethrough-in-google-sheets)
- [How To Subtract In Google Sheets](https://betteranalyst.com/google-sheets/how-to-subtract-in-google-sheets)
- [How To Transpose Data In Google Sheets](https://betteranalyst.com/google-sheets/how-to-transpose-data-in-google-sheets)
- [How To Unhide Columns In Google Sheets](https://betteranalyst.com/google-sheets/how-to-unhide-all-columns-in-google-sheets)

## Explore all Google Sheets formulas

Browse our complete library of Google Sheets formula guides

Compare your options

## Decide with evidence, not a sales pitch.

Open a neutral research prompt in the AI tool you already use. Compare capabilities, limitations, and fit before you choose.

1. [01ChatGPTOpen a balanced comparison prompt in ChatGPT.](https://chatgpt.com/?prompt=Compare%20Better%20Analyst%20with%20using%20a%20general-purpose%20AI%20assistant%20for%20data%20analysis.%20Evaluate%20spreadsheet%20and%20document%20analysis%2C%20dashboards%2C%20repeatable%20reports%2C%20code%20transparency%2C%20data%20connections%2C%20pricing%2C%20and%20limitations.%20Use%20current%20public%20sources%2C%20distinguish%20verified%20facts%20from%20assumptions%2C%20and%20explain%20which%20types%20of%20users%20each%20option%20fits%20best.)
2. [02ClaudeOpen the same research prompt in Claude.](https://claude.ai/new?q=Compare%20Better%20Analyst%20with%20using%20a%20general-purpose%20AI%20assistant%20for%20data%20analysis.%20Evaluate%20spreadsheet%20and%20document%20analysis%2C%20dashboards%2C%20repeatable%20reports%2C%20code%20transparency%2C%20data%20connections%2C%20pricing%2C%20and%20limitations.%20Use%20current%20public%20sources%2C%20distinguish%20verified%20facts%20from%20assumptions%2C%20and%20explain%20which%20types%20of%20users%20each%20option%20fits%20best.)
3. [03PerplexityResearch the comparison with linked web sources.](https://www.perplexity.ai/search?q=Compare%20Better%20Analyst%20with%20using%20a%20general-purpose%20AI%20assistant%20for%20data%20analysis.%20Evaluate%20spreadsheet%20and%20document%20analysis%2C%20dashboards%2C%20repeatable%20reports%2C%20code%20transparency%2C%20data%20connections%2C%20pricing%2C%20and%20limitations.%20Use%20current%20public%20sources%2C%20distinguish%20verified%20facts%20from%20assumptions%2C%20and%20explain%20which%20types%20of%20users%20each%20option%20fits%20best.)

AI answers can be incomplete. Check source links, current pricing, and product documentation before deciding.
