Close the Window Shortcut Key for Windows, Mac and Chromebook
You have too many windows open. Your screen looks like a messy desk. You want to clear it fast, and you do not want to grab the mouse.
There is a simple close the window shortcut key for every major system. On Windows, it is Alt+F4. On a Mac, it is Command+W. On a Chromebook, it is Ctrl+Shift+W.
This article shows each shortcut step by step. It also clears up the mix-ups that trip people up, like closing a window versus quitting an app. And if a window refuses to close, you will find a fix below.
Quick Answer: Close the Window Shortcut Key by System
Here is the short version:
- Windows: Alt+F4
- Mac: Command+W to close the window, Command+Q to quit the app
- Chromebook: Ctrl+Shift+W
- Linux: Alt+F4 on most desktops
- Browser tab: Ctrl+W on Windows, Linux and Chromebook, Command+W on Mac
Each shortcut works on the window you are using right now. If you are not sure which window is active, click it once first.
Close the Window Shortcut Key on Windows
Press Alt+F4. Hold down the Alt key, then tap F4. The active window closes, just like when you click the X in the top right corner.
If the window has unsaved work, Windows usually asks if you want to save it first. That gives you a chance to stop.
One more thing. If you press Alt+F4 on an empty desktop, Windows opens the Shut Down box. So do not tap it twice without looking.
Other Windows Shortcuts That Close Things
These look alike, but each one does a different job.
- Ctrl+W closes the current tab in a browser. Many apps use it too.
- Ctrl+F4 closes the current file inside an app that opens many files.
- Ctrl+Shift+W closes the whole browser window in Chrome, Edge and Firefox.
- Alt+Space, then C opens the window menu and picks Close. It is a handy backup.
- Win+Ctrl+F4 closes your current virtual desktop, not just one window. Skip it unless that is what you want.
What If Alt+F4 Does Not Work on Your Laptop?
Many laptops use the top row keys for volume and screen brightness. In that case, press Fn+Alt+F4. Some laptops also have an Fn Lock key, often on the Esc key, that switches the top row back to normal F keys.
Close the Window Shortcut Key on Mac
A Mac does not use Alt for this. It uses the Command key. Press Command+W and the front window closes. If you are in a browser, it closes the current tab.
Here is something that surprises new Mac users. Closing a window does not always quit the app. The app can keep running in the background. You will see a small dot under its icon in the Dock. To shut the app all the way, press Command+Q.
If you come from Windows, think of it this way. Command+W closes the window. Command+Q closes the app. Alt+F4 does a bit of both.
More Mac Window Shortcuts
- Option+Command+W closes all windows of the app you are in.
- Shift+Command+W closes the whole window in Safari and Chrome.
- Command+M tucks the window into the Dock.
- Command+H hides the app.
- Command+Option+Esc opens the Force Quit box.
For more key combos, check this list of Mac keyboard shortcuts.
Set Your Own Close Shortcut on a Mac
You can pick your own keys. Open System Settings, then Keyboard, then Keyboard Shortcuts, then App Shortcuts. Click the plus button. Choose All Applications. Type Close Window as the menu title, then press the keys you want.
Close the Window Shortcut Key on Chromebook
On a Chromebook, press Ctrl+Shift+W. The current window closes. To close only one tab, press Ctrl+W.
Closed it by mistake? Press Ctrl+Shift+T to bring the tab back. Our list of Chromebook keyboard shortcuts has more keys like this.
Close the Window Shortcut Key on Linux
Most Linux desktops, including GNOME, KDE Plasma and XFCE, use Alt+F4 to close a window. Many apps also quit with Ctrl+Q. Ctrl+W closes a tab. Keys can change by desktop, so check your system settings if one does not work.
Window, Tab or App: Know the Difference
A window is the box on your screen. A tab is a page inside a browser window. An app is the program itself.
When you close a tab, the other tabs stay open. When you close a window, all its tabs close with it. When you quit an app, every window of that app closes. Picking the right shortcut keeps you from closing more than you meant to.
What to Do When a Window Will Not Close
Sometimes the shortcut does nothing. The app may be frozen or busy. Try these steps in order.
- Click the window once, then press the shortcut again.
- Wait about ten seconds. The app may be saving or loading.
- On Windows, press Ctrl+Shift+Esc to open Task Manager. Pick the app and click End task. Our post on the Task Manager keyboard shortcut shows more ways to open it.
- On a Mac, press Command+Option+Esc. Pick the app and click Force Quit. You can read more about the force quit shortcut on Mac too.
Force closing can lose unsaved work. Use it only as a last step.
Tips to Avoid Losing Your Work
- Save first. Press Ctrl+S on Windows or Command+S on a Mac.
- Tap Alt+F4 once, not many times. Holding it can close several windows in a row.
- Look in the File menu. Most apps show the close shortcut next to Close or Close Window.
- Reopen a closed browser tab with Ctrl+Shift+T on Windows or Command+Shift+T on a Mac.
Which Close the Window Shortcut Key Should You Remember?
Pick the one for the computer you use most. On Windows, remember Alt+F4. On a Mac, remember Command+W. On a Chromebook, remember Ctrl+Shift+W. Add Ctrl+W or Command+W for tabs, and you cover most daily needs.
Practice each key a few times today. In a week, your hand will press it without thinking.
Frequently Asked Questions
What is the close the window shortcut key on Windows?
It is Alt+F4. Press it while the window is active, and the window closes.
What is the close the window shortcut key on a Mac?
It is Command+W. Use Command+Q if you want to quit the whole app.
Is Alt+F4 the same as Ctrl+W?
No. Alt+F4 closes the window or app. Ctrl+W closes one tab or file inside it.
How do I close all windows at once?
On a Mac, press Option+Command+W to close all windows of the app in front. On Windows, there is no single key for it. Right-click the app icon on the taskbar and pick Close all windows.
Can I change the close shortcut on Windows?
Windows has no setting for it. A free tool called PowerToys has a Keyboard Manager that can remap keys.
Final Thoughts
The close the window shortcut key is a small habit that saves time every day. Use Alt+F4 on Windows, Command+W on a Mac, and Ctrl+Shift+W on a Chromebook. Save your work first, and use Task Manager or Force Quit only when a window is stuck. Pick one shortcut today and use it on your next three windows.








