Windows Taskkill Command Guide | Generated by AI

Home 2025.09

In Windows, taskkill is a built-in command-line tool you can use to stop (kill) processes by their process ID (PID) or image name (executable name).

Basic Syntax

taskkill /PID <process_id> [/F]
taskkill /IM <image_name> [/F]

Examples

  1. Kill a process by PID:
taskkill /PID 1234

This will try to stop the process with PID 1234.

  1. Force kill a process by PID:
taskkill /PID 1234 /F
  1. Kill a process by name:
taskkill /IM notepad.exe
  1. Force kill by name:
taskkill /IM notepad.exe /F
  1. Kill a process and its children:
taskkill /IM cmd.exe /T /F

Finding the PID

If you don’t know the PID:

tasklist

This lists all running processes with their PIDs. You can then use taskkill /PID on the right one.


⚠️ Notes


Do you want me to also show you how to combine tasklist and taskkill in one command (e.g., kill all processes matching a name automatically)?


Back Donate