shortcutsguide

Close Window Shortcut (Alt+F4 / ⌘W)

Close the active window with ⌘W on Mac and Ctrl+W (or Alt+F4 to close the app) on Windows. Here it is with quit.

ActionMacWindows
Close window ⌘W Ctrl+W
Close app entirely ⌘Q Alt+F4
Close tab ⌘W Ctrl+W
Close all windows (app) ⌘⌥W —
Reopen closed tab ⌘⇧T Ctrl+Shift+T

Close a window vs quit the app

On Windows Ctrl+W closes the current window, tab or document, while Alt+F4 quits the whole application. On the Mac ⌘W closes the front window and ⌘Q quits the app — a distinction Windows mostly lacks.

Careful with Alt+F4

Alt+F4 closes with no confirmation in many apps, so save first. To close every window of a Mac app at once, use ⌘⌥W.

FAQ

What is the close-window shortcut?

On Windows Ctrl+W closes the window or tab and Alt+F4 quits the app. On the Mac ⌘W closes the window and ⌘Q quits the app.

What is the difference between ⌘W and ⌘Q?

⌘W closes just the front window; ⌘Q quits the entire application and all its windows.

How do I reopen a window I closed by accident?

In browsers press Ctrl+Shift+T (⌘⇧T on Mac) to reopen the last closed tab or window.