taskkill ends running processes from the command line. It’s faster than Task Manager when an app is frozen, it works in scripts, and it can stop processes on another computer on your network.
Find the process first
tasklistntasklist /fi u0022imagename eq chrome.exeu0022Syntax
taskkill [/s Computer [/u Domainu005cUser [/p Password]]] [/fi Filter] [/pid ProcessID | /im ImageName] [/t] [/f]| Option | Meaning |
|---|---|
/im | Image (executable) name, e.g. notepad.exe. Wildcards like note* work. |
/pid | Process ID from tasklist or Task Manager. |
/f | Force – end the process immediately, without letting it save. |
/t | Tree – also end child processes it started. |
/fi | Filter, e.g. by status, user, memory or window title. |
/s /u /p | Target a remote computer, optionally with other credentials. |
Everyday examples
rem End Notepad, forcefullyntaskkill /im notepad.exe /fnnrem End a process and everything it startedntaskkill /pid 4120 /t /fnnrem End every app that is u0022Not Respondingu0022ntaskkill /fi u0022status eq not respondingu0022 /fnnrem End a user's Excel on a remote PCntaskkill /s PC-042 /u CORPu005cadmin /im excel.exe /fUseful filters
| Filter | Example |
|---|---|
| Status | /fi "status eq not responding" |
| User | /fi "username eq CORPjsmith" |
| Memory (KB) | /fi "memusage gt 500000" |
| Window title | /fi "windowtitle eq Untitled*" |
| Service | /fi "services eq spooler" |
Use /f with care
Forced termination skips “do you want to save?” prompts, so unsaved work is lost. Never end system processes such as csrss.exe, wininit.exe or lsass.exe – Windows will crash. Ending processes owned by other users or services needs an administrator prompt.
In PowerShell the equivalent is Stop-Process -Name notepad -Force or Stop-Process -Id 4120.

