Disable automatic application termination in OS X

Aug 02, '12 07:30:00AM

Contributed by: paulbrainerd

If you leave certain applications running without any open windows, OS X will quit the application when it goes to the background. This happens with some Apple apps such as TextEdit and Preview, and perhaps others. There is no user setting to change this in preferences. Here is a Terminal command line to change this feature:

defaults write -g NSDisableAutomaticTermination -bool TRUE

Change “TRUE” to “FALSE” to re-enable it.

[kirkmc adds: What's interesting is when OS X kills an application using this feature, the app still shows up in Activity Monitor. Matt Neuberg has a good overview of this at TidBITS. This has been around since Lion, and I'm surprised there hasn't been a hint yet. The submission specified Mountain Lion, and it's possible that this "feature" is more aggressive in 10.8, but I found mention of this command from before Mountain Lion.]

Comments (21)


Mac OS X Hints
http://hints.macworld.com/article.php?story=20120726192014497