The fastest way to close all tabs depends on your browser

Most browsers let you close every open tab in seconds using a keyboard shortcut or menu command, rather than clicking the X on each one individually. The method differs slightly between Chrome, Firefox, Safari, and Edge, but each one has a built-in feature designed for this exact task.

If you have dozens of tabs open and want to start fresh, or if your browser is running slowly because of too many open pages, closing them all at once is faster than closing them one by one. You can also save your tabs before closing them if you think you might need them later.

Key Takeaways

  • Chrome, Firefox, Safari, and Edge all have keyboard shortcuts to close every tab at once — usually Ctrl+Shift+W on Windows or Command+Shift+W on Mac.
  • If you close all tabs by accident, you can reopen them when ready using Ctrl+Shift+T (or Command+Shift+T on Mac) to restore your last closed window.
  • Saving your tabs to a bookmark folder before closing them lets you reopen all of them together later without losing track of them.
  • Some browsers let you close all tabs except the current one using a right-click menu, which is useful if you want to keep one page and discard the rest.

Close all tabs in Chrome

In Chrome on Windows, press Ctrl+Shift+W. On Mac, press Command+Shift+W. This closes every tab in your current window and closes the window itself.

If you only want to close all tabs but keep the window open, use Ctrl+W (or Command+W on Mac) repeatedly, or open a new blank tab after closing the others. Chrome does not have a built-in option to close all tabs while leaving the window open, so closing the window and reopening it is the standard approach.

If you close all your tabs by accident, press Ctrl+Shift+T (or Command+Shift+T on Mac) when ready to reopen the entire window with all the tabs you just closed. This works only once — if you close the window again, the first set of tabs is gone.

Close all tabs in Firefox

In Firefox on Windows, press Ctrl+Shift+W. On Mac, press Command+Shift+W. Like Chrome, this closes all tabs and the window itself.

To close all tabs except one, right-click the tab you want to keep and select Close Other Tabs. This is useful if you are browsing multiple topics and want to discard everything except the page you are currently reading.

If you close all tabs by accident, press Ctrl+Shift+T (or Command+Shift+T on Mac) to reopen your last closed window with all its tabs restored. Firefox remembers your last several closed windows, so you can press this shortcut multiple times to go back further if needed.

Close all tabs in Safari

Safari does not have a single keyboard shortcut to close all tabs at once. Instead, use the menu: click File at the top, then select Close All Tabs. On Mac, you can also press Command+Option+W to close all tabs in the current window.

To close all tabs except one, right-click the tab you want to keep and select Close Other Tabs. If you close all tabs by accident, press Command+Z to undo the action and restore them when ready.

Close all tabs in Microsoft Edge

In Edge on Windows, press Ctrl+Shift+W. On Mac, press Command+Shift+W. This closes all tabs and the window itself, just like Chrome and Firefox.

To close all tabs except the current one, right-click any tab and select Close other tabs. If you close all tabs by accident, press Ctrl+Shift+T (or Command+Shift+T on Mac) to reopen your last closed window.

Save your tabs before closing them all

If you think you might want to reopen some of your tabs later, save them to a bookmark folder first. In Chrome, right-click any tab and select Bookmark all tabs. In Firefox, go to Bookmarks menu and select Bookmark All Tabs. In Safari, use Bookmarks menu and choose Add Bookmarks for These Tabs. In Edge, right-click a tab and select Bookmark all tabs.

This creates a folder in your bookmarks with the title and link of every open tab. You can rename the folder to something descriptive like "Research for Project" or "Shopping Sites" so you remember what it contains. Later, you can open the entire folder at once, which reopens all the tabs in one action.

Another option is to use your browser's built-in tab groups or tab management features. Chrome lets you group tabs by color or label, Firefox has tab containers, and Safari has tab groups — these features help you organize tabs without closing them, which is useful if you want to keep your tabs but separate them by topic.

What happens when you close all tabs

When you close all tabs using the keyboard shortcut, your browser window closes completely. Your browsing history is saved — closing tabs does not delete your history — but the tabs themselves are gone unless you reopen them using the undo shortcut or restore them from a bookmark folder.

Some browsers offer a feature to reopen your tabs automatically the next time you start the browser. In Chrome, go to Settings, click On startup, and select Continue where you left off. In Firefox, go to Settings, scroll to Home, and under Tabs select Restore previous session. This setting means your tabs will reopen even if you close the browser completely, so you do not have to manually restore them.

Frequently Asked Questions

Can I close all tabs except one without using a menu?

Most browsers do not have a keyboard shortcut for this, but all of them let you right-click a tab and select Close Other Tabs or Close other tabs. This closes every tab except the one you right-clicked on. It is faster than closing them individually but requires one right-click action.

Will closing all tabs delete my browsing history?

No. Closing tabs only closes the tabs themselves. Your browsing history, bookmarks, and saved passwords remain in your browser. If you want to delete your browsing history, you must use your browser's clear history or privacy settings, which is a separate action.

What if I close all tabs by accident?

Press Ctrl+Shift+T (Windows) or Command+Shift+T (Mac) when ready to reopen your last closed window with all its tabs. This works only once — if you close the window again, the first set of tabs cannot be recovered this way. If you wait too long or close other windows first, use your browser's history to navigate back to the pages you need.

Can I set my browser to close all tabs when I close the browser?

Yes, but the setting varies by browser. In Chrome, Firefox, Safari, and Edge, you can turn off the "restore previous session" or "continue where you left off" setting in preferences. This means your tabs will not reopen the next time you start the browser — they will be gone unless you manually restore them from history or bookmarks.

Is there a way to close all tabs on all windows at once?

No. Each browser closes all tabs in one window at a time. If you have multiple browser windows open, you must close each window separately using the keyboard shortcut. If you want to close your entire browser and all its windows, use Alt+F4 (Windows) or Command+Q (Mac) instead.