How to Close All Tabs in Salesforce: Lightning & Classic

The fastest way to close all tabs in Salesforce is the keyboard shortcut Shift+W, which instantly closes every unpinned workspace tab in a Lightning Console app. There is no clickable button in the interface to do this, so keyboard shortcuts are your primary option.

Close All Tabs in Lightning Console

Salesforce’s Lightning Experience Console does not have a “Close All Tabs” button anywhere in the UI. Instead, you have two keyboard shortcuts that get the job done.

Shift+W closes all unpinned workspace tabs at once. This is the true “close all” shortcut. It works regardless of which tab you currently have selected, so you can press it from anywhere in the console. Any tabs you’ve pinned will stay open.

Shift+X closes the single workspace tab you’re currently viewing, along with any subtabs nested under it. If you hold down Shift+X rather than tapping it once, it repeats rapidly and closes tabs one after another. Some users prefer this as a quick alternative when they want to watch tabs close sequentially or when Shift+W isn’t responding as expected. The key difference: you need to be on an active tab for Shift+X to work, while Shift+W does not have that requirement.

What Happens to Pinned Tabs

Pinned tabs are protected from both shortcuts. When you press Shift+W, every unpinned tab closes but your pinned tabs remain exactly where they are. This makes pinning a useful habit for tabs you reference throughout the day, like a dashboard or a key account record, since you won’t accidentally wipe them out when clearing your workspace.

Closing Tabs in Salesforce Classic

If you’re still using the Salesforce Classic console, the options are more limited. Pressing “C” closes the single tab you’re currently viewing. Classic does not offer a built-in keyboard shortcut to close all open tabs at once. Your best workaround is to tap “C” repeatedly to close tabs one at a time, or to simply refresh the browser window if you want a clean slate (keeping in mind that refreshing resets your entire console session).

Enabling Keyboard Shortcuts

These shortcuts only work inside console apps, not in standard Lightning navigation apps. If pressing Shift+W does nothing, check two things. First, confirm you’re using a console app rather than a standard app. You can tell by looking at the navigation style: console apps use a tab bar across the top where records open as new tabs, while standard apps navigate you away from the current page. Second, verify that your Salesforce admin hasn’t disabled keyboard shortcuts for the console. Admins control this setting in the app’s configuration, and shortcuts are enabled by default.

If you’re unsure which app you’re in, click the App Launcher (the grid icon in the top-left corner) and look for an app labeled as a console, such as “Service Console” or “Sales Console.” Switching to that app will give you access to the full set of keyboard shortcuts.

Quick Reference

  • Close all unpinned tabs (Lightning Console): Shift+W
  • Close current workspace tab and its subtabs (Lightning Console): Shift+X
  • Close current tab (Salesforce Classic): C