Home » How To » How To Close All Apps at Once on Windows 11 & 10

How To Close All Apps at Once on Windows 11 & 10

On Windows, you can close any open application by clicking the X button on the title bar. Alternatively, you can also right-click the app icon on the taskbar and choose Close Window or End Task. However, the limitation of this method is that you can only close one window at a time. What if you want to close multiple windows at once? In this tutorial, we’ll show you two simple methods to quickly close all windows using PowerShell, Command Prompt, or even a custom shortcut. Let’s get started.

Command to Close All Apps at Once

To start off, right-click on the Windows logo and choose Terminal (Admin). This opens the Windows terminal with the PowerShell tab active. If not, click the down arrow icon on the terminal’s title bar and choose Windows PowerShell.

open Windows terminal as admin Windows 11

In the terminal window, copy & paste the below command and press Enter to run it.

Get-Process |? {$_.MainWindowTitle -ne "" -and $_.Id -ne $PID -and $_.ProcessName -ne "explorer"} | Stop-Process -Force

That’s it. As soon as you run the command, except File Explorer, all open apps are forcefully closed, whether minimized or maximized.

Create a Shortcut to Close All Apps

If you are looking for a quicker way to close all apps, you can create a desktop shortcut. Here’s how:

First, go to the desktop by pressing Windows key + D. On the desktop, right-click and choose New and then Shortcut.

Paste the below command in the location field and click Next.

PowerShell -Command "Get-Process |? {$_.MainWindowTitle -ne \"\" -and $_.Id -ne $PID -and $_.ProcessName -ne \"explorer\"} | Stop-Process -Force"

Type Close All Windows in the name field and press Finish.

name the shortcut

That’s it. Double-click on the shortcut whenever you want to close all apps and open windows quickly. Just as with the first method, the shortcut will close all except File Explorer.

(Optional) If you don’t like the default shortcut icon, you can change it. To do that, right-click on the shortcut icon, select Properties, and then click on Change Icon. Choose the icon of your choice and click OK.

And there you have it. It’s that simple.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top