To filter an Excel table by text in Microsoft 365 for Windows, select the drop-down arrow in the column heading, point to Text Filters, choose a condition such as Contains or Begins With, enter the text, and select OK. Excel hides rows that do not match; it does not delete them.
What a text filter does
An Excel table filter displays only the rows that meet a condition you choose. For example, filtering a Region column for text that contains “north” can show both North and Northeast while hiding other regions. The table’s underlying data remains in the workbook, and clearing the filter makes the hidden rows visible again.
Text filters are useful when a column contains labels, names, codes, descriptions, or other text values. They work on table columns and on ordinary ranges with AutoFilter turned on. Tables are convenient because their header row includes filter controls by default, and a new table row is normally included when you add data directly below the table.
Filter an Excel table by text step by step
- Click a cell inside the table. Confirm that each column has a header, such as Customer, Region, or Status.
- Select the arrow at the right side of the heading for the column you want to filter. If the arrow is not visible, check that the table has a header row and that filtering is enabled.
- Point to Text Filters. Choose a condition such as Contains, Equals, or Begins With.
- In the Custom AutoFilter dialog box, type the text to match. Depending on the condition, you may enter one or two values.
- Select OK. Excel leaves matching records visible and hides the others.
For instance, to find product descriptions that include “adapter,” open the filter for the Description column, choose Text Filters > Contains, enter adapter, and apply the filter. The match does not need to be at the start of the cell. To find descriptions that start with “adapter,” choose Begins With instead.
On Windows, the ribbon command for enabling or disabling filters is Data > Filter. In Excel for Mac, select the table or range and use Data > Filter as well; the menus may be arranged differently from Windows. Excel for the web also provides filter arrows on tables, although some dialog details can vary by browser and update.
Choose the right text condition
The condition determines how Excel compares the cell contents with the text you enter. The main choices answer different questions:
- Equals: Shows cells whose text matches the criterion. Use it for a specific category such as Open.
- Does Not Equal: Excludes the specified text value while retaining other values.
- Begins With: Finds a prefix, such as product codes beginning with AB.
- Ends With: Finds a suffix, such as file names ending in .pdf.
- Contains: Finds the criterion anywhere within the cell, such as a street name containing Park.
- Does Not Contain: Keeps rows whose cells do not include the specified text.
- Custom Filter: Lets you set two text conditions and decide whether both must be true or either can be true.
Choose the narrowest condition that matches your goal. If you need every row with a particular status, Equals is clearer than Contains. A Contains filter for “open,” for example, could also match a longer label such as “reopened.” That may be useful for searching, but it is not equivalent to an exact category match.
Combine conditions and use wildcards
Custom AutoFilter can combine two conditions for the same column. Choose And when a cell must satisfy both conditions, or Or when either condition is enough. For example, a Status column can be filtered to equal Open Or Pending to show both groups. An And condition that requires a value to begin with A and end with Z is more restrictive and may return no rows if no entries meet both rules.
For more flexible matching, Excel’s AutoFilter criteria support wildcard characters. An asterisk (*) represents any number of characters, while a question mark (?) represents one character. A tilde (~) lets you search for a literal wildcard character rather than use it as a pattern. For example, a criterion like AB* can match text beginning with AB, and ~* represents a literal asterisk. Use wildcards in the filter criterion when the built-in condition is not specific enough; do not assume that typing an asterisk into every search box will behave identically.
Text matching in Excel filters is not case-sensitive. A criterion of north can match North or NORTH. If case matters, the normal table filter is not a case-sensitive search tool; use a formula or another method that explicitly tests capitalization.
Filter search box or Text Filters?
The search box in a column’s filter menu is a quick way to locate particular entries in the list. Type part of a value, then select the matching item or items shown in the menu. This is especially handy when a column contains many distinct values and you want to select a few known labels.
Text Filters are better when you want to express a rule rather than select individual displayed values. For example, searching the item list for “North” helps select the listed North value, while Contains can return cells containing North as part of longer text, such as Northeast. The search box and condition menu can be used together in the filter menu, but check the selected checkboxes before applying a filter: a prior selection can restrict what remains visible.
To show every row in a column again, open its filter menu and choose Clear Filter From followed by the column name. To remove filters from the whole range, use Data > Clear. Clearing a filter is different from turning filter controls off: the first restores hidden rows, while disabling filtering removes the arrows from the headings.
Check text values, spaces, and mixed data
A filter can only match what is actually stored in the cells. Two entries that look identical may differ because one has a leading or trailing space, a nonbreaking space copied from a web page, or a different punctuation mark. If a value that appears to match is missing, inspect the source cell in the formula bar and compare it with a known working entry.
Mixed data can also make results confusing. A column may contain text labels alongside numbers, dates, or values that look numeric but are stored as text. Excel groups filter menu items according to the data it recognizes, so a value may not appear where expected. Keep each table column to one kind of information where possible—for example, store a customer code in one column and a date in another.
For inconsistent imported text, clean a copy of the data before filtering. The TRIM function can remove ordinary extra spaces at the beginning and end of text and reduce repeated spaces between words, but it does not remove every invisible character that may come from external sources. Preserve the original column if the source values need to remain unchanged, and verify cleaned results before replacing source data.
Common problems and practical fixes
- The filter arrow is missing: Click inside the table and check Data > Filter. Also check whether the table header row is enabled and whether the worksheet is protected in a way that prevents filtering.
- Expected rows are absent: Clear other active filters. Filters on different columns work together, so a row must pass every active column filter to remain visible.
- New records do not appear: Confirm the records are inside the table. Data pasted several rows below or beside the table may not be included in its filter range.
- A partial-word search returns unexpected results: Use Equals instead of Contains for an exact label, or use Begins With or Ends With for a position-specific match.
- Filtering seems to leave no results: Check for extra spaces, spelling variations, or a condition left over from an earlier filter. Reopen the menu and clear the column filter before applying the intended one.
- The filter menu shows only some values: Another filter may already be limiting the visible records. Clear the other filters if you want to work from the full table.
Hidden rows are not removed from calculations or the workbook simply because a filter hides them. If you copy filtered data, check whether the destination should contain only visible rows and use Excel’s visible-cells-only selection when that distinction matters. Filtering is a view of the records, not a permanent edit to the table.
When a formula is a better alternative
Use a formula when you need a separate, automatically updated list of matching records rather than temporarily hiding rows in the original table. The FILTER function is available in Microsoft 365 and Excel 2021 or later. It returns matching records in another area of the worksheet, leaving the source table unchanged.
Assume the headers are in A1:C1, rows 2 through 7 contain records, and the Region values are in B2:B7: North, South, North, West, Northeast, and South. In Microsoft 365 or Excel 2021 or later, enter this formula in an empty cell outside the source table:
=FILTER(A2:C7,ISNUMBER(SEARCH("north",B2:B7)),"No matches")
SEARCH finds north without regard to capitalization, and ISNUMBER marks the rows where it was found. The formula returns the three matching records whose Region values are North, North, and Northeast; it displays No matches if none qualify. Leave enough empty cells beneath and to the right of the formula for the results to spill. Unlike a table filter, this result is a separate output range and updates when the source values change.
Frequently Asked Questions
Can I filter an Excel table for text that appears anywhere in a cell?
Yes. Open the relevant column’s filter arrow, choose Text Filters > Contains, enter the text, and apply it. Excel finds the text within the cell, not only at the beginning.
Can I filter for two words in the same column?
Yes. Choose Text Filters > Custom Filter, enter the first condition, select And or Or, and enter the second. Use And when both conditions must match and Or when either can match.
Does an Excel text filter distinguish uppercase and lowercase?
No. Standard table text filters are case-insensitive, so north can match North and NORTH. Use a formula designed for case-sensitive comparison if capitalization is essential.
How do I remove a text filter without deleting data?
Open the filtered column’s menu and choose Clear Filter From that column, or use Data > Clear to clear filters more broadly. The rows are revealed; the data is not deleted.
Why does Contains return more rows than Equals?
Contains matches the text anywhere within a cell, including as part of a longer word or label. Equals is the appropriate choice when you want the complete cell value to match the criterion.
Related
- Average Excel File Size: What to Expect and Why It Varies
- Excel Sum Shortcut Keys: AutoSum, Examples, and Tips
- Excel Sum Keyboard Shortcut: Use AutoSum in Seconds
Try it: the Formula Explainer: paste any formula and see each function and reference in plain English.
More in Formulas & functions
- Excel Sum Rows Based on Cell Value: Formulas That WorkTo total values in rows where a cell matches a condition, use Excel’s SUMIF function. With categories in…
- Excel: How Many Days Between Dates? Simple FormulasTo find how many days separate two dates in Excel, subtract the start date from the end date:…
- Replace an Excel Cell Value: Methods, Formulas, and TipsTo replace a value in one Excel cell, select the cell, type the new value, and press Enter;…
- Excel Sum Same Cell Across Tabs: The 3-D Formula GuideIf the sheets you want to total are next to one another in the workbook, use a 3-D…
- Excel CONCAT: Join Cell Values with a FormulaTo combine cell values in Excel, use the CONCAT function: with text in A2 and B2, enter =CONCAT(A2,B2)…
- Filter Excel Table by Color: Steps and TroubleshootingYes. In Excel for Microsoft 365 on Windows, open the filter arrow in the table column containing the…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.