Mac OS X Prefs Editor - A GUI for the 'defaults' command
(a.k.a. the Registry Editor for macOS)
Go directly to the Download button.
Prefs Editor can edit application and system preferences in a simple, tabular format.
See also this blog article explaining its features from another person's point of view.
First, choose which preferences domain you want to edit:
If the list is long, enter part of the app's name into the Filter field to limit the list to matching names. Alternatively, you can drag and drop the plist file from the Preferences folder or the Application into this window or onto the Dock icon.
(Note: You can also open the user's globals domain from the File menu. Hold down the option (⌥) key to open the globals-host).
Once you have opened a preference, you'll see a list of key-value pairs, like this:
You can now click on the values in the rightmost column to edit them, add new values by clicking on the [+] button at the bottom-left (or by pressing the Return key) or delete one or more items by selecting them and using the [-] button. You can also Copy & Paste. You can Undo (cmd+Z) all modifications as well.
Of course, you should know what you're doing, or at least be instructed, as messing with the wrong values can cause the app that owns these preference to malfunction. If you messed it up, first try to Undo your changes using the Edit / Undo menu command. If that doesn't help, you can also delete them all (type cmd+A, then the Delete key), then restart the related app to have it reset all its prefs to its defaults as if it was just launched for the first time.
Some apps play along nicely and will notice changes to their preferences immediately. Other apps will need to be restarted manually for changes to take effect - the latter may also reset your changes if they're running while you're making changes. If in doubt, quit the app before using Prefs Editor on their preferences.
Click here to see instructions on adding a Quit menu to Finder as an example of using this tool.
Start by opening Finder's preferences. Launch Prefs Editor (if it's already running, type cmd+shift+O to open the domains chooser), then type "finder" into the top-right search field:
Select com.apple.finder and open it.
In the new window showing Finder's preferences, click the [+] button at the lower left or press the Return key. In the next dialog, enter QuitMenuItem (case matters!) for the Key and select Boolean for the Type (or press cmd+5):
You have now added a new key named "QuitMenuItem" of type Boolean with the value YES to Finder preferences.
(This particular key was found by others that dug deeper into the operations of Finder. It's what we call an undocumented or secret preference key. Many apps have such keys for handling special cases that would be supplied only when needed, e.g. by their support team.)
Now relaunch Finder to have it recognize our modification. The easiest way is to log out and in again. A quicker way is to right-click (or ctrl-click) on Finder in the Dock while holding down the option (⌥) key. This will show an additional "Relaunch" option in the menu:
Once Finder has relaunched, check its File menu and a new Quit menu item should appear:
Let's do one more improvement: We'd like to change the keyboard shortcut for Finder's Quit command from ⌘Q to ⌘⌥Q to prevent accidentally quitting Finder. The normal way to change such shortcuts is to open the Keyboard Control Panel from the System Preferences app, and then add a new shortcut under Shortcuts / App Shortcuts. But we'll do this using the Prefs Editor now to show how to add keys to Array and Dictionary entries.
Let's go back to viewing Finder's preferences in Prefs Editor and add another entry named NSUserKeyEquivalents, which is the key for defining new keyboard shortcuts in an app (this works with any app), and set its type to Dictionary (if the Add button remains disabled, it means there is already a key with this name, so you can skip this step):
The just-added entry is now selected. Press the cursor-right key to open its triangle. Only if the triangle is opened (pointing down) can new entries be added to this item as children:
Add another entry named Quit Finder, which is the title of the Quit menu item, and set its type to String:
The final step is to add the new shortcut code for the Quit Finder entry. Enter @~q as seen here:
Now you're done. Relaunch Finder once again and verify that its Quit command now shows ⌘⌥Q:
Background Information (Technical)
Mac OS X 10.8 introduced a caching system for app preferences ("cfprefsd"). While this probably increases performances for apps, it makes it harder for developers to manipulate preference values quickly for testing, because making changes directly to the plist files in the ~/Library/Preferences folder does not work any more with editors such as "Property List Editor.app" and the similar editor in Xcode. As of now (Dec 14, 2013), the only way to edit such preferences is by using the "defaults" command, which is rather difficult to use once it comes to editing dict or array entries.
Therefore, I've written a tool that works like the plist editor in Xcode but uses the CFPreferences functions to modify the values instead of editing the plist files directly.
If you've worked with "Property List Editor" or Xcode, you should find yourself right at home with my tool. It even supports Copy & Paste in the same way.
It even has one feature that Xcode's editor doesn't: You can delete all entries at once with Select All, then delete.
Also note that due to the use of the CFPreferences API, any changes you make are immediately committed to the preferences as seen by other apps, just like when you use the "defaults" command. For the same reason, changes made to the prefs by other apps (or with the "defaults" tool) will be seen in this tool after a modification, by re-activating the app or by using the "Sync" command from the menu. Hence, there is no Save command - updates are instant.
If you are an app developer and want to make your app more responsive to changes with Prefs Editor, please consider invoking CFPreferencesAppSynchronize or [NSUserDefaults.standardUserDefaults synchronize] whenever your app gets reactivated (i.e. in the NSApplicationDelegate's applicationWillBecomeActive: handler). This ensures that any changes to your prefs will be loaded back into your app's defaults cache.
Current version: 1.3, requires Mac OS X 10.10 or later (Release Notes)
Using OS X 10.6, 10.7, 10.8 or 10.9? Download version 1.2.4 for Mac OS 10.6 - 10.9.
Known Issues & Limitations:
- Can only edit actual application preferences, not general plist files (to edit plist files use Xcode, PrefEdit or BBEdit).
- Dragging rows to move or copy them is not supported. Use Cut & Paste as a work-around.
Editing sandboxed prefs was made possible with help from @_karsten_
This project uses quite a lot of Xojo code written by Charles Yeomans, the UndoToolkit by Scott Forbes and some MBS plugins.
Alexandre Colucci from Elgato Systems made a few good suggestions that went into 1.0.3.
Steve from Irradiated Software encouraged and helped me releasing version 1.2.