close
close

How to customize the macOS dock to only display running apps

The macOS Dock displays the apps you add or launch to it. Here’s how to make it only show apps currently running on your Mac.

The macOS Dock application is derived from the early forerunners of the macOS operating system, NeXTStep and OpenStep, which were created at another of Steve Jobs’ companies, NeXT Computer. In 1997, Apple purchased NeXT and with it acquired NeXT technology.

NeXTStep was modified by Apple, and in 2000 Apple re-released it as Mac OS X, which combines most of the NeXTStep core (which became Darwin in macOS) with features and file systems from Apple’s older Mac OS 9.

Early versions of the two combined operating systems were named Rhapsody.

NeXTStep interface showing the file manager, mailboxes and system menus.

Original NeXTStep desktop. Note the Dock on the right.

One of the applications specific to NeXTStep was the Dock – a small bar that could be displayed on the edge of the display. The Dock stores applications, files, folders and other objects from the file system to provide shortcuts.

Changes to the dock

Over the years, Apple has improved the Dock somewhat – including the ability to hide or show it on demand, adjust its size and zoom, and indicate which apps are running. Most of these changes can be made in macOS System settings application today.

Apple has also added the ability to minimize Finder windows, apps, and documents in the Dock, again based on configuration within the Dock System settings->Desktop and docking station. Just about the only thing the macOS Dock can’t do today that the original NeXT Dock can do is tear off tiles containing individual icons for single applications.

You can turn it on System Settings->Desktop & Dock->Show suggested and recently used apps in the Dock. When this option is enabled, the Dock will also display apps you might like, as well as recently used apps.

System settings showing Dock preferences, including size, zoom, screen position, and toggle options.

Show suggested and newest apps in the Dock in System Settings.

You can also add some file system objects such as files, folders, disk volumes, and aliases to the remote object Normal side of the Dock, behind the small vertical partition where Trash lives. To add a volume or folder to the right side of the Dock, simply drag it there in the Finder.

If you right click item in the Dock with your mouse, you can display the item it represents in the Finder, remove it from the Dock, or set it to launch at login. If you right click file system item on the right side of the Dock, you can set stack and folder options, open it, set sorting options, or delete it.

Hidden features

The Dock has several settings and hidden features that are stored in a .plist preferences file on your startup disk at /Users/user/Library/Preferences/com.apple.dock.plist, where “user” is the currently active name of the logged in user. A .plist file is simply a formatted XML file containing key/value pairs.

If you open com.apple.dock.plist with a text editor, you will see the file’s XML code which you can edit. Alternatively, you can open the file in Apple’s Xcode, select it in the project navigator, and then edit it in the right-hand pane.

In either case, if you edit the file, simply save it and then reload the Dock (described below) or Log out and sign in again on your Mac.

You should be careful when changing the value of com.apple.dock.plist because it is possible to set various items to values ​​that will render the Dock unusable. First, create a backup of your com.apple.dock.plist file if you are editing it, in case you want to restore it later.

You can also edit Dock features using the Terminal app default values order. To see how the default settings work, type in Terminal:

then press Return on the keyboard. To exit the manual system, press Control-Z on the keyboard.

“Default Settings” is basically a way to edit macOS preferences and settings using the command-line interface.

A NeXT computer with a monitor displaying the NeXTSTEP login screen.

Original NeXT cube, display and keyboard.

To edit default settings, you usually type defaultsa space, a subcommand followed by the name of the reverse domain of the setting you want to change (called domain), the name of the setting, then the new value followed by Return.

For example, to show all hidden files in the macOS Finder, in Terminal, type:

defaults write com.apple.Finder AppleShowAllFiles true

There are other default commands such as read, delete, renameand more. You can dump all settings on your Mac by typing:

and pressing Return. Be warned that this will dump a huge amount of information into the terminal.

You can even hack your Dock to insert blank spaces and group apps. We will discuss this in a future article.

For the Dock, if you edit the com.apple.dock.plist file or change one of its settings using the system default, you will need to restart the Dock. This can be done either by logging out and back in, or by pressing a button killall command in terminal:

killall Dock and press Return.

When Finder reloads the Dock, it will re-read the com.apple.dock.plist file and reset the Dock accordingly.

In 2021, Apple has made some changes to system security requirements for apps. On some versions of macOS, the com.apple.dock.plist file may be encrypted.

In this case, you need to open it in Xcode to edit it. Always back up your file first and always test your changes before throwing away your backup.

To edit a file in Xcode, simply create a copy of it on your desktop in Finder, then drag and drop the file onto the Xcode application icon in /Applications. First you need to download Xcode from the App Store.

View only running applications

The dock can sometimes become unwieldy. If you add too many items or run multiple apps at once, it may be difficult to find what you’re looking for.

Around 2018, Apple added a new (possible) setting in the default domain com.apple.dock: static-only. This setting determines whether only running applications are displayed in the Dock.

But Apple NO add static-only setting to just com.apple.dock.plist. To use this setting, you must do so write use the defaults command in Terminal or add it to the com.apple.dock.plist file in Xcode.

Dock so that only icons of running applications are at the bottom.

Show only running apps in the macOS Dock.

static-only Is A logical value which in computer science terminology means that it is a true or false value. Or in Apple programming terminology: YES or NO.

Xcode displays these values ​​as type Boolean with YES or NO being the only two possible values. To make your Dock visible Just running applications and excluding everything else, add the file static-only Boolean, set its value to YES and save the .plist file.

You will then need to restart the Dock, Finder or Log out and log back in (or restart) your Mac.

In detail, the steps to add this value to the com.apple.dock.plist file in Xcode after opening it are as follows:

  1. Control-click anywhere in the empty part of the .plist window
  2. To choose Add value from the pop-up menu
  3. Settings Key field to static-only
  4. Settings Type field to Boolean
  5. Settings Value field to YES

Save the file, back up the original file from the Preferences folder in Finder, and then replace the old file with the new one (you will need to enter your administrator password).

Once the new file is in place, Log outand then sign in again, restart your Dock, or restart your Mac.

When the Dock loads, only running applications will now be displayed. To reverse the setting and display the Dock normally, set static-only back to YES and repeat the same process as above.

If you don’t want to go through the trouble of editing the .plist file directly, you can toggle the same setting using the defaults in Terminal:

defaults write com.apple.dock static-only -bool true

defaults write com.apple.dock static-only -bool false

After each command is issued killall Dock give the command again and press Return: :

An Xcode window displaying the com.apple.dock.plist file.

Added “static only” setting to com.apple.dock.plist.

Additional cool .plist settings

The com.apple.dock.plist file contains some other interesting settings:

  1. latest programs
  2. magnification (magnification)
  3. persistent applications (all Dock applications)
  4. launchanim (Application launch animation)
  5. Trash-Full (Whether or not the Trash contains items
  6. wvous-br-corner (Hot corners)

To dump only the Dock settings in Terminal, type:

defaults read com.apple.dock

From this data, you can see what the key names and values ​​are for all of your current Dock settings.

The Dock has been with us for decades – since Mac OS X in 2000 and even before that on NeXT systems. Users either love the Dock or hate it, but it’s here to stay, and with customization you can make the most of it.