PDF download Download Article
Using the taskkill command to end Windows processes
PDF download Download Article

Taskkill is a Windows Command Prompt (cmd) command that ends one or more tasks. It's kind of like ending a task with Task Manager, but from the command line. [1] Taskkill can also do things like forcefully end a program if it won't close normally, or it can terminate multiple programs at once. For most people, Task Manager is the best program to use, but knowing taskkill is useful if you are writing a program, or if you need to do something more advanced. This wikiHow article will teach you how to use the taskkill command to force quit programs on your Windows PC.

Running the Taskkill Command in Windows

Open the Command Prompt app and type in "tasklist." Find the program you want to end. Type in "taskkill /IM [Image Name of the program]" and hit "Enter." Type " /F" at the end of the command to forcefully end the process. To end all non-responsive programs, type "taskkill FI "STATUS eq NOT RESPONDING" /F."

Method 1
Method 1 of 3:

Ending a Process

PDF download Download Article
  1. Click start
    Windows Start
    , type Command Prompt into the search bar, and then click on "Command Prompt"
    Windows cmd
    in the results.
    • To start Command Prompt as administrator, right-click it, and select "Run as administrator". You will need to do this to end any programs that are also running as administrator.
  2. 2
    Type in tasklist . This will display all running processes on the computer. [2] It's important to run this command first so that you can find the process names of the ones that you want to terminate.
    Advertisement
  3. 3
    Review the list. Review the task list to search for the program that you want to end. Look at the "Image Name" specifically, since you will need this information to kill the task.
    • You will probably have to scroll down to review all of the processes since they won't fit all on one page.
  4. 4
    Kill the task. First, you need to type in taskkill . Then, you have to specify that you are killing the task based on its image name, so put in a space, and then type in /IM . After this, put in another space, and then type in the Image Name of the program that you want to end. For this example, notepad.exe will be the task that will be killed. Afterwards, press Enter . This will kill the task.
    • For this example, the whole command would look like taskkill /IM notepad.exe .
  5. Advertisement
Method 2
Method 2 of 3:

Forcefully Ending a Process

PDF download Download Article
  1. 1
    Type in tasklist . Just like the previous task, you need to type in tasklist to view the running programs and to retrieve the image name.
  2. 2
    Type in the regular taskkill command. You would first type in the command like your normally would. For example, to forcefully kill notepad.exe, you would type in taskkill /IM notepad.exe .
  3. 3
    Add /F to the end of the command. The "/F" argument tells taskkill that you want to forcefully end the process. Keep in mind that you have to add a space before adding this argument.
  4. Advertisement
Method 3
Method 3 of 3:

Ending all Non-Responsive Programs

PDF download Download Article
  1. 1
    Type in taskkill . This is the beginning of the command.
  2. 2
    Type /FI "STATUS eq NOT RESPONDING" . This specifies that you want to kill all programs that are not responding. Remember that you need to add a space after taskkill .
  3. 3
    Add /F to the end. Since non-responsive programs will not close on their own, they need to be forcefully closed. Then, press Enter . This will end all non-responsive programs.
    • Remember to add the space before typing /F .
  4. Advertisement

Expert Q&A

Ask a Question
      Advertisement

      Tips

      • The taskkill command is not case sensitive
      • There are many other things that taskkill can do, but most people will not need to use them. You can view all arguments for the taskkill command here .
      • Be careful with the command prompt. Although taskkill cannot really harm your computer, other commands can cause damage. You can always see what a command does by typing the first part, and then typing in /? after it.
      Submit a Tip
      All tip submissions are carefully reviewed before being published
      Name
      Please provide your name and last initial
      Thanks for submitting a tip for review!
      Advertisement

      About This Article

      Thanks to all authors for creating a page that has been read 81,320 times.

      Is this article up to date?

      Advertisement