Sub topic 6
Reset one app's preferences
This chapter covers resetting a single app's preferences without touching the rest of your Mac. It assumes you can open Terminal and run a command. It also assumes you have read the earlier chapters on force quitting and backing up, because a preference reset is the next step after "quit and relaunch" fails. You should also know your account name and be able to open the Library folder in Finder.
What a preference file is
When you change a setting in an app, such as a window size, a default folder, or a toolbar layout, macOS stores it in a preference file. These files are property lists (plists), named after the app's bundle identifier. A bundle identifier is a reverse-domain name that identifies an app uniquely, for example com.apple.dock.
A corrupted or incompatible preference file can cause symptoms such as:
- The app crashes at launch, or right after it shows its window.
- The app opens with strange layouts, missing toolbars, or ignores your changes.
- The app hangs on startup, but only for your user account.
If another user account on the same Mac can run the app normally, a preference file in your account is a likely cause. Resetting preferences is a narrow fix. It affects one app for one user, and your documents and other apps stay untouched.
Where preferences live
Most preferences are in your user Library, which is hidden by default.
| Location | Contents |
|---|---|
| `~/Library/Preferences/` | Plist files for most apps, named `bundle-id.plist` |
| `~/Library/Containers/<bundle-id>/Data/Library/Preferences/` | Plist for sandboxed apps (all Mac App Store apps, many Apple apps) |
| `~/Library/Application Support/<app>/` | Data, plug-ins, and sometimes settings |
| `~/Library/Caches/<bundle-id>/` | Temporary data the app can rebuild |
| `/Library/Preferences/` | Settings shared by all users (leave alone unless instructed) |
The ~ means your home folder. To open the hidden Library folder, choose Go in the Finder menu bar, hold the Option key, and click Library.
The container location catches many people out. A sandboxed app is restricted to its own container folder. If you look in ~/Library/Preferences/ and find no plist for the app, check its container before concluding the app has no preferences.
Find the bundle identifier
You need the exact identifier. This command asks macOS for it:
osascript -e 'id of app "TextEdit"'It prints com.apple.TextEdit. Replace TextEdit with the app's name. You can also search the preferences folder by name:
ls ~/Library/Preferences | grep -i texteditThe reset workflow
The process has the same shape for every app. Backup comes before any change, as in the previous chapter.
flowchart TDReplace that placeholder with the diagram below.
Step 1: Quit the app completely
Quit the app, and force quit it if it will not close. If you do not, the app can write its old settings back to disk and undo your reset. Use Activity Monitor to confirm no process with the app's name remains.
Step 2: Move the file, do not delete it
Moving the plist is reversible. Deleting it is not. This is the example from the chapter plan, with the backup folder created first:
mkdir -p ~/Desktop/prefs-backup
mv ~/Library/Preferences/com.example.App.plist ~/Desktop/prefs-backup/Replace com.example.App with the real identifier. The -p option makes mkdir succeed even if the folder already exists. If mv reports "No such file or directory", the app is probably sandboxed. Look in its container path instead:
mv ~/Library/Containers/com.example.App/Data/Library/Preferences/com.example.App.plist ~/Desktop/prefs-backup/Step 3: Relaunch and test
The app creates a fresh plist with defaults the next time it launches. You will likely see a first-run state: a welcome screen, lost window positions, or a request to sign in again. That is expected and confirms the reset worked.
Step 4: Restore if it did not help
If the problem remains, the preferences were not the cause. Quit the app and move the file back so you do not lose your settings for nothing:
mv ~/Desktop/prefs-backup/com.example.App.plist ~/Library/Preferences/A caching gotcha: cfprefsd
macOS runs a background service called cfprefsd that caches preferences in memory. Apps usually read through it instead of reading the file directly. If you move a plist and the old settings still seem to appear, the cache may be serving them. Restarting the service forces a re-read:
killall cfprefsdmacOS restarts it automatically. Do this after quitting the app and moving the file, and before you relaunch the app. Without this step, a reset sometimes seems to do nothing, which leads people to wrongly conclude that preferences are not the problem.
Use `defaults` for system-managed apps
Some apps, such as the Dock, are best reset through the defaults command, which reads and writes preferences through the same cache the app uses. First look at what is set:
defaults read com.apple.dockBack it up in a form you can restore:
mkdir -p ~/Desktop/prefs-backup
defaults export com.apple.dock ~/Desktop/prefs-backup/com.apple.dock.plistThen reset it and restart the Dock:
defaults delete com.apple.dock
killall DockThe Dock comes back with the default size, position, and icons. Pinned items return to the defaults, so your own pinned apps disappear from the Dock. The apps stay installed, so you can drag them back. To restore everything from your backup:
defaults import com.apple.dock ~/Desktop/prefs-backup/com.apple.dock.plist
killall DockCompare the two approaches:
| Approach | Best for | Reversible with |
|---|---|---|
| Move the plist | Most third-party and sandboxed apps | Moving the file back |
| `defaults delete` | Dock, Finder, and other system components | `defaults import` of an export |
| Remove the app's Application Support folder | Corrupted data or plug-ins (a bigger reset) | Only a Time Machine backup |
Common errors
- Wrong identifier. Names are case-sensitive and not always obvious.
com.apple.finderis lowercase whilecom.apple.TextEditis not. Use theosascriptcommand rather than guessing. - Several plist files. Some apps keep more than one file, such as
com.example.App.plistandcom.example.App.helper.plist. Move only the main file first. Move the others only if the problem remains. - Files with a random suffix. Files like
com.example.App.ABC123.plistunder~/Library/Preferences/ByHost/are per-machine settings. They are safe to move the same way, but tackle them after the main file. - Resetting the wrong thing. If a problem appears in every app, preferences for a single app are not the cause. Go to safe mode or a test user account instead.
- Permission errors. Do not use
sudoto move files in your own Library. If you need it, the file's ownership is wrong, and that is a clue that something else is broken. - App data loss. Apps such as password managers, mail clients, and note apps may keep their accounts and data in Application Support. Resetting only the plist is generally safe. Removing other folders might not be, so check your backup first.
How this fits the larger routine
A preference reset sits between "quit and relaunch" and "test with a new user account." It is more disruptive than a force quit, because you lose settings. It is less disruptive than safe mode or reinstalling macOS, because only one app is affected. If the reset fixes the problem, note which app and file it was, because the bug may return after an update. If it does not, restore the file and move on to the next step in the plan.
Exercise
An app crashes every time you open it. You quit it, moved ~/Library/Preferences/com.example.Notes.plist to a backup folder, and relaunched it. It opens with default settings, but the old, broken layout is still there. What are two likely explanations, and what should you try?
Show answer
The app may be sandboxed, so its real preferences are in ~/Library/Containers/com.example.Notes/Data/Library/Preferences/, and the file you moved was not the active one. Or cfprefsd is still serving cached values. Quit the app, move the container plist (or confirm the file you moved was the right one), run killall cfprefsd, and relaunch. If the problem is still there, restore the file you moved and try a test user account.
Exercise
Why is defaults export followed by defaults delete safer than only running defaults delete com.apple.dock?
Show answer
The export saves the current settings to a plist file. If the reset does not help, or you lose a layout you wanted, defaults import restores it. defaults delete alone has no undo.