Would you like to learn how to use the FINDSTR command on a computer running Windows? In this tutorial, we are going to show you multiple ways to use the FINDSTR command, which is the Windows equivalent of the GREP command from Linux.

• Windows 2012 R2
• Windows 2016
• Windows 2019
• Windows 10

Windows - Related Tutorial:

On this page, we offer quick access to a list of tutorials related to Windows.

Tutorial Findstr  - Filter the command output

Start a new command-line prompt.

Windows DOS Prompt

List the status of all services installed on Windows

Copy to Clipboard

Here is the command output:

Copy to Clipboard

Use the FINDSTR command to filter only the lines containing the word RUNNING.

Copy to Clipboard

Keep in mind that the FINDSTR command is case sensitive.

Here is the command output:

Copy to Clipboard

This command specifies that the search is not to be case-sensitive.

Copy to Clipboard

Use the FINDSTR command to filter multiple strings.

Copy to Clipboard

Here is the command output:

Copy to Clipboard

In our example, we used the FINDSTR filter to show only lines containing the words: AMAZON and BITS.

Tutorial Findstr  - Filter the file content

Start a new command-line prompt.

Windows DOS Prompt

Create a text file named TEST.

This text file contains the list of software installed on the computer.

Copy to Clipboard

Use the FINDSTR command to list all lines containing the word PYTHON.

Copy to Clipboard

Here is the command output:

Copy to Clipboard

Use the FINDSTR command to list all lines not containing the word PYTHON.

Copy to Clipboard

Here is the command output:

Copy to Clipboard

In our example, we used the FINDSTR filter to show only selected lines from a text file.