11

I have added a number of entries to the Favorites section of the left sidebar in Finder windows. Every now and then, all the entries I carefully curated disappear from the Favorites section. How can I restore them?

I am running macOS 12.6 Monterey.

Note: Someone asked a similar question back in 2013 about Mac OS X 10.8.3 Mountain Lion. This is basically the same question, but about operating systems from Big Sur on. The answer is different now.

3 Answers 3

10

tl;dr: Restore the folder ~/Library/Application Support/com.apple.sharedfilelist (using TimeMachine etc). Then, either log out and back in, or restart macOS. (It is not enough to relaunch Finder.)


On Ventura (and probably also on Monterey and perhaps older versions), you can retrieve your favorites on the Finder sidebar (which suddenly disappeared after a random macOS bug) with this manipulation, if you have Time Machine:

Go to your local Library (~/Library), for example by holding down the option key when you go in the Finder's Go menu (the option key displays the otherwise hidden Library in the menu item). Then go to "Application Support", then "com.apple.sharedfilelist", and finally in this folder is a file named "com.apple.LSSharedFileList.FavoriteItems.sfl2". This file contains the sidebar items.

Go to Time Machine, then navigate to a date before the items disappear to restore an older version of the file. You will probably need to choose few hours before, when the file size was bigger. For example, if after some items disappear, the file is 6 KB in size; and few hours before, it was 13 KB, restore the 13 KB file.

I restart the Mac to retrieve all the favourites items in the Finder's sidebar. Perhaps it is sufficient to just quit the user session, then log in again. But, in my experience, relaunching the Finder (by holding the option key down and click on Finder's Dock to choose "Relaunch") doesn't change anything.

If you don't have Time Machine, you can manually backup the com.apple.LSSharedFileList.FavoriteItems.sfl2 file.

2
  • I just experienced this problem on macOS 12.6.5 Monterey, and this answer successfully fixed it. It was sufficient to log out and log back in again to retrieve all the favourites in the Finder's sidebar. I did not need to restart macOS. Commented May 9, 2023 at 1:09
  • Has anybody found a solution to permanently fix items disappearing? I don't bother putting back the 3-4 founders into the sidebar. The issue is that they keep disappearing every few days.
    – Kevin
    Commented Sep 14, 2023 at 9:04
4

There is a command line tool called mysides, which allows you to List sidebar favorites items, Append a new item to the end of a list, Insert a new item at the start of the list, and Remove the item (by name).

mysides can be installed in Terminal via Homebrew by using the command brew install mysides

After mysides has been installed, the first thing I did was to list of all of my Finder sidebar favorites (removing "-> " from each line of the output) and wrote that to file ~/Desktop/My_Sidebar.txt ... With this following command in Terminal.

/usr/local/bin/mysides list |sed -E 's@-> @@g' > ~/Desktop/My_Sidebar.txt

If "On%20My%20Mac x-finder:OnMyMac" ...appears in the ~/Desktop/My_Sidebar.txt file then remove that line from the file.

The next thing I did was to retrieve only the names of all of my Finder sidebar favorites from the ~/Desktop/My_Sidebar.txt file and saved that output to file ~/Desktop/My_Sidebar_Names.txt ... With this following command in Terminal.

cut -d " " -f 1 ~/Desktop/My_Sidebar.txt > ~/Desktop/My_Sidebar_Names.txt

The file ~/Desktop/My_Sidebar_Names.txt will be the file I use to loop through and remove each item from my Finder sidebar favorites so that next I can go back and restore everything.

This following one line of code in Terminal.app will remove all of Finder sidebar favorites.

cd ~/Desktop ;while read -r line ;do /usr/local/bin/mysides remove "$line" ;done < My_Sidebar_Names.txt 2>&1 >/dev/null

Then, this following one line of code in Terminal.app will restore all of Finder sidebar favorites.

cd ~/Desktop ;while read -r line; do /usr/local/bin/mysides add $line ;done < My_Sidebar.txt 2>&1 >/dev/null

This following animation demonstrates restoring my Finder sidebar favorites after I had removed them all.

enter image description here

2
-3

This has been a long standing UI design failure in macOS. For obvious reasons you are not likely to be able to find anything official from Apple about this behaviour. I certainly haven't for several years or more.

Basically, network and other removable (i.e. non-persistent) items, including items (files or folders) that exist on non-persistent volumes, such as network and removable drives, will always disappear from the Finder Favourites, when the non-persistent volume or item item is not visible to macOS. i.e. macOS Finder Favourites are for local or system defined items only.

2
  • I have given them a definitive answer to their question and clarification around the behaviour of the issue they have described.
    – Deejinoz
    Commented May 2, 2023 at 8:15
  • The commonly experienced issue the OP is asking about was that sidebar favourites for items on the local disk are the ones that disappear. Nothing to do with network/removable non-persistent volumes. Your response does not answer their question at all. Moreover, sidebar favourites to network/removeable locations ABSOLUTELY DO persist in the sidebar. For many months. Even if the destination server is unreachable. This has been a feature of macOS since day 1 of the sidebar. So your answer was not only unrelated, but wrong.
    – MrTemple
    Commented Oct 17, 2023 at 16:44

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .