In Excel for Microsoft 365 on Windows, open the filter arrow on the column you want to check, choose Text Filters > Does Not Contain, enter the text, and select OK. To create a separate, automatically updated list instead of hiding rows in place, use Excel’s FILTER function with a condition that rejects cells containing that text.
Choose what “exclude text” means
Before filtering, decide whether you want to exclude a whole cell value or any cell that includes a phrase. These are different tests. If a Status column contains “Open,” “Closed,” and “On hold,” excluding the exact value “Open” leaves “On hold” visible. Excluding text that contains “on” could also remove “On hold,” because those characters occur within the longer value.
Excel’s text filters can check whether a cell contains, begins with, ends with, or equals text. The opposite options let you exclude a match. “Does Not Contain” is usually the right choice for phrases that might appear anywhere in a cell; “Does Not Equal” is appropriate when only one complete cell value should be removed. Both are text comparisons, and the built-in filter is not case-sensitive.
For example, if a list of notes includes “urgent review,” “not urgent,” and “routine,” Does Not Contain urgent excludes the first two. That is useful for removing every row mentioning a keyword, but it would be the wrong choice if you intended to exclude only the exact entry “urgent.”
Use Excel’s built-in text filter
Apply the filter to a table or a continuous range with a header row. In the Windows ribbon, select a cell in the data and choose Data > Filter if the column arrows are not already displayed. Then use these steps:
- Open the drop-down arrow in the header of the column containing the text.
- Point to Text Filters, then choose Does Not Contain.
- Type the word or phrase to exclude in the filter dialog.
- Select OK. Excel hides rows whose cells contain that text.
For an exact-value exclusion, use Text Filters > Does Not Equal and enter the complete value. The menu can also offer Does Not Begin With or Does Not End With, which are useful when the unwanted text follows a consistent naming pattern. For instance, excluding values that begin with “TEMP-” removes temporary codes without excluding a phrase that happens to contain TEMP later in the cell.
In a formatted Excel table, filter arrows usually appear in the header automatically. On Mac and Excel for the web, the filter controls work much the same way, although the ribbon layout can differ slightly. The relevant column’s filter menu remains the place to look for text-filter options.
Exclude more than one phrase
You can exclude two phrases from the same column in one custom filter. Open the column’s filter arrow, choose Text Filters > Does Not Contain, and enter the first phrase. In the dialog, set the second condition to Does Not Contain, enter the other phrase, and select And. For example, using Does Not Contain “urgent” AND Does Not Contain “draft” keeps a row only when its cell contains neither term.
The choice between And and Or matters. Two negative conditions joined by And exclude both terms: a cell must pass both tests to remain visible. Joined by Or, the conditions are much looser: a cell can remain if it does not contain either one of the terms, even if it contains the other. When your goal is to remove every row containing either “urgent” or “draft,” choose And.
Excel’s custom text-filter dialog is convenient for a small number of criteria. If you need to exclude a longer list of terms, a helper column or formula is easier to maintain than stacking several manual filter conditions. Also remember that filters on separate columns work together: a row must meet the active filter conditions to stay visible.
Generate a separate filtered list with FILTER
A normal AutoFilter hides rows in the original data; it does not produce a second, independent result list. Excel’s FILTER function is useful when you want a live output elsewhere in the workbook. It is available in Microsoft 365 and Excel 2021 or later. The function spills matching rows into nearby cells, so leave enough empty space for the results.
Assume A2:C6 contains five records, with IDs in column A, names in B, and notes in C. Suppose the notes are “Urgent review,” “Routine,” “not urgent,” “Closed,” and a blank, in that order. To return entire records only when the note is nonblank and does not contain urgent, enter this formula in an empty cell:
=FILTER(A2:C6,(C2:C6<>"")*ISERROR(SEARCH("urgent",C2:C6)),"No matching rows")
With that sample, the result contains the Routine and Closed records—the second and fourth rows of the source. The formula excludes “not urgent” as well as “Urgent review” because SEARCH looks for the text anywhere in a cell. SEARCH is not case-sensitive, so it finds “Urgent” even though the search term is lowercase. The nonblank test prevents the empty note from being included; without that test, a blank cell can pass the “does not contain” condition.
The first argument, A2:C6, is the range to return. The condition is calculated from the corresponding notes in C2:C6, and the asterisk combines the two TRUE/FALSE tests as an AND condition. The final text is what FILTER displays if no rows match. To make the output grow as you add records, convert the source range to an Excel table and use structured references, or extend the formula’s ranges to cover the expected data. Do not place a spilling formula inside the source table itself.
Use a helper column for a filterable TRUE/FALSE test
A helper column can make a large or repeatedly updated list easier to inspect. Add a header such as “Keep row?” beside the data, enter a test on the first data row, and copy it down. Then filter the helper column to show TRUE. This preserves the original rows and makes the reason for each inclusion or exclusion visible.
Assume the note to check is in C2, and the helper formula is entered on the same row. To mark nonblank notes that do not contain urgent, use:
=AND(C2<>"",ISERROR(SEARCH("urgent",C2)))
For the sample notes above, this returns FALSE for “Urgent review,” TRUE for “Routine,” FALSE for “not urgent,” TRUE for “Closed,” and FALSE for the blank. Copy the formula down, then filter the helper column to TRUE. If you need a case-sensitive test, FIND is the case-sensitive alternative to SEARCH; keep in mind that FIND returns an error when it cannot locate the text, so the ISERROR pattern is still useful for an exclusion test.
Filtering is not the same as deleting
AutoFilter changes which rows are displayed; it does not remove the excluded records from the workbook. Clear a filter to show them again. In the column menu, choose Clear Filter From [column name], or use Data > Clear to clear filters on the current range. The exact wording can vary with the selected column, but clearing a filter restores visibility rather than reconstructing deleted data.
Take care if you plan to copy or delete visible rows after filtering. A filtered view can make a selection look like one continuous block even though hidden rows sit between the visible ones. Check the selected range and the command you intend to use before making changes. If you need an output that leaves the source intact, a FILTER formula is generally a clearer option than deleting rows from the filtered source.
Common reasons the result looks wrong
- The wrong kind of match was chosen. Does Not Contain excludes partial matches; Does Not Equal excludes only cells equal to the entered value.
- A blank appears unexpectedly. A blank does not contain the search phrase, so a “does not contain” test can include blanks. Add a nonblank condition if blanks should be removed.
- Extra spaces or punctuation change the text. A cell with a trailing space may not equal the clean value you typed. Check the original cell contents if an exact comparison seems to miss a row.
- The filter range missed some records. A blank row or a separate block of data can cause Excel to treat part of a list as a different range. Use a table or select the full contiguous range, including its headers.
- The condition is case-insensitive. Excel’s built-in text filters and SEARCH do not distinguish uppercase from lowercase. Use FIND in a formula if capitalization must matter.
- A formula output has nowhere to spill. FILTER needs clear cells for its results. Remove blocking contents or move the formula to an empty area.
If a visible row still seems surprising, inspect the full cell value and verify whether the requirement is about a substring, an exact value, or capitalization. Those distinctions explain many apparent filter errors.
Frequently Asked Questions
How do I exclude an exact word in Excel?
Open the column’s filter arrow, choose Text Filters > Does Not Equal, enter the complete cell value, and select OK. If you want to exclude cells containing that word as part of a longer phrase too, choose Does Not Contain instead.
Can Excel exclude two words at once?
Yes. Set two Does Not Contain conditions in the custom text-filter dialog and join them with And to remove rows containing either word. For a larger list of phrases, use a helper formula or a dynamic FILTER formula instead of managing many manual conditions.
Does “Does Not Contain” distinguish uppercase and lowercase?
No. Excel’s built-in text filter is case-insensitive. SEARCH is also case-insensitive in formulas; FIND is the function to use when the capitalization of the searched text should matter.
Will filtering delete the excluded rows?
No. A filter hides rows from view but leaves the underlying data in place. Clear the filter to display the rows again. A FILTER formula also leaves its source data untouched, while returning matching rows in a separate output area.
Why is a blank row still showing?
A blank cell does not contain the excluded phrase, so it can pass a Does Not Contain test. If blanks should not appear, add a separate nonblank condition in a formula or exclude blank values in the filter menu.
Related
- Excel DOS Keyboard Shortcuts: What Actually Works
- Excel Direct Access vs Link: What’s the Difference?
- Excel Desktop Keyboard Shortcuts: A Practical Guide
Try it: the Formula Explainer: paste any formula and see each function and reference in plain English.
More in Formulas & functions
- Structured References in Excel Formulas: A Practical GuideStructured references are Excel table references that use a table’s name and column headings instead of ordinary cell…
- Power Query Filter: How to Filter Rows in ExcelTo filter in Power Query, open the query in Power Query Editor, select the filter arrow in a…
- VLOOKUP Examples for Practice: Learn Excel Lookup SkillsFor a first VLOOKUP practice problem, put product IDs in A2:A6, prices in B2:B6, and the lookup ID…
- Excel MID Function: Extract Text from the Middle of a CellExcel’s MID function extracts a chosen number of characters from the middle of a text string. Its syntax…
- Excel Formula Line Break: How to Add One in a CellTo put a line break in an Excel formula, join the text with CHAR(10), then turn on Wrap…
- Excel CONCATENATE With Commas: Formulas and ExamplesTo concatenate two Excel cells with a comma and a space between them, use =A2&", "&B2. For a…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.