Getting rid of ghost login items in macOS Ventura
April 2, 2023
Let’s say you uninstalled an app on macOS Ventura, and you see some leftovers from that app in System Settings > General > Login Items:
Here’s a few tips to solve it.
More often than not, it seems that after removing login items and/or the app behind then, it takes a reboot of macOS Ventura until they’re “garbage collected” from system settings. That’s the first thing you should try.
If you moved the app to the trash but didn’t empty the trash, its login items are still referenced from the trash! They won’t go away until you permanently delete the app (and reboot).
There’s a few places macOS looks for “login items” on your filesystem:
Also, same thing under
/System/Library but that’s for macOS own login
items and you have no control over them.
Check the 4 directories above for leftover
plist files from the
applications you removed. You may need to do some cleanup. After that,
don’t forget to reboot!
As shown in this Reddit post,
the list of login items in Ventura is managed in
/private/var/db/com.apple.backgroundtaskmanagement. In my case, in a
file /private/var/db/com.apple.backgroundtaskmanagement/BackgroundItems-v8.btm Apple binary property list
file(1) tells us, this is a binary property list file. We can
inspect it with
plutil -p /private/var/db/com.apple.backgroundtaskmanagement/BackgroundItems-v8.btm
This will print the whole structure behind that file. From inspecting its output, you should be able to determine what’s behind the “ghost items” that you identified in the system settings. More often than not, it’ll point to some file or app that you forgot to get rid of, and cleaning that up will fix your problem (again, after a reboot).
Note: if when accessing
/private/var/db you get a permission
denied error, even as
root, make sure to grant “full disk access”
permission to your terminal app!