I am constantly running multiple applications on multiple workspaces. I want to remain on the same workspace, and only switch workspaces when I explicitly ask for it (e.g. with a magic mouse gesture).

Currently when I click on the app icon in the dock, osx switches to the next workspace that has a window of the active application.

I know there is an option in System Preferences -> Misson Control, called "When switching to an application, switch to a space with open windows for the application". What it does: When clicking on the icon of an inactive application, don't switch to a workspace that has the application window. But this option does not affect the behaviour of clicking on an active application.

The question: How do I prevent OSX from ever switching to another wokspace when clicking on an app icon in the dock, regardless of whether the app is active of inactive?

  • 3
    Do you have a fix for MacOS Sierra? This doesn't seem to work anymore...
    – user206976
    Commented Oct 19, 2016 at 22:33

3 Answers 3


For macOS 10.11 El Capitan and earlier only:

Open Terminal.app, then run the following commands.

Change the default workspace preference:

defaults write com.apple.dock workspaces-auto-swoosh -bool NO  

Next, restart the Dock with this command:

killall Dock

How can I disable auto-switching desktops?
Disable Space switching on Command-Tab

  • It's worth noting that this solution also disables the swtiching from any other dock action, like application exposé view or the right-click full application window list. Nonetheless, I like it much more. Thanks! Commented Sep 13, 2013 at 5:53
  • 4
    This doesn’t work in MacOS 10.12 (Sierra) and later versions. Commented Nov 5, 2019 at 2:04
  • 1
    This does not work on Catalina
    – ToniAz
    Commented Jul 31, 2020 at 14:20

Unlike the original questioner, I was trying to enable this effect. I wanted to switch between spaces where applications lived on different desktops.

I just took a guess at:

defaults write com.apple.dock workspaces-auto-swoosh -bool TRUE


killall Dock

The two commands above worked like a charm to restore the effect.

  • Still not working on MacOS Sierra 10.12 and later versions... Commented May 8, 2020 at 11:17

Note that there is a relevant setting in later versions of MacOS when using the app switcher (cmd+tab), but that doesn't work when clicking on the app icon in the Dock (so it doesn't solve the OPs question):

System Preferences > Mission Control > "When switching to an application, switch to a Space with open windows for the application"

  • 3
    This does not solve the problem Commented Mar 23, 2021 at 9:44
  • @MichaelSchmid It works for me on Catalina if I use the app switcher (cmd+tab), but you're right that it doesn't work when clicking on the icon in the Dock.
    – Jonathan H
    Commented Mar 25, 2021 at 6:38

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .